Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Haroon-Dweikat-Ntx committed Dec 16, 2024
1 parent c94cff8 commit 4bdb65f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions nutanix/services/prismv2/resource_nutanix_backup_target_v2.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ func ResourceNutanixBackupTargetV2Update(ctx context.Context, d *schema.Resource

clusterConfigBody.Config = clusterRef

err := oneOfBackupTargetLocation.SetValue(*clusterConfigBody)
err = oneOfBackupTargetLocation.SetValue(*clusterConfigBody)
if err != nil {
return diag.Errorf("error while setting cluster location : %v", err)
}
Expand All @@ -319,7 +319,7 @@ func ResourceNutanixBackupTargetV2Update(ctx context.Context, d *schema.Resource
objectStoreLocationBody.ProviderConfig = expandProviderConfig(providerConfig)
objectStoreLocationBody.BackupPolicy = expandBackupPolicy(backupPolicy)

err := oneOfBackupTargetLocation.SetValue(*objectStoreLocationBody)
err = oneOfBackupTargetLocation.SetValue(*objectStoreLocationBody)
if err != nil {
return diag.Errorf("error while setting object store location : %v", err)
}
Expand Down Expand Up @@ -417,7 +417,7 @@ func ResourceNutanixBackupTargetV2Delete(ctx context.Context, d *schema.Resource
}

func expandProviderConfig(providerConfig interface{}) *management.AWSS3Config {
if providerConfig == nil || len(providerConfig.([]interface{})) == 0 {
if len(providerConfig.([]interface{})) == 0 {
return nil
}
providerConfigI := providerConfig.([]interface{})
Expand Down Expand Up @@ -451,7 +451,7 @@ func expandAccessKeyCredentials(credentials interface{}) *management.AccessKeyCr
}

func expandBackupPolicy(policy interface{}) *management.BackupPolicy {
if policy == nil || len(policy.([]interface{})) == 0 {
if len(policy.([]interface{})) == 0 {
return nil
}

Expand Down

0 comments on commit 4bdb65f

Please sign in to comment.