Skip to content

Commit

Permalink
Merge pull request #1801 from k8s-infra-cherrypick-robot/cherry-pick-…
Browse files Browse the repository at this point in the history
…1795-to-release-1.29

[release-1.29] fix: panic when cloud config is not set
  • Loading branch information
andyzhangx authored Apr 5, 2024
2 parents 8e1e13b + edecff9 commit 581460a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/azurefile/azurefile.go
Original file line number Diff line number Diff line change
Expand Up @@ -1056,8 +1056,8 @@ func (d *Driver) GetTotalAccountQuota(ctx context.Context, subsID, resourceGroup

// RemoveStorageAccountTag remove tag from storage account
func (d *Driver) RemoveStorageAccountTag(ctx context.Context, subsID, resourceGroup, account, key string) error {
if d.cloud == nil {
return fmt.Errorf("cloud is nil")
if d.cloud == nil || d.cloud.StorageAccountClient == nil {
return fmt.Errorf("cloud or StorageAccountClient is nil")
}
// search in cache first
cache, err := d.skipMatchingTagCache.Get(account, azcache.CacheReadTypeDefault)
Expand Down

0 comments on commit 581460a

Please sign in to comment.