diff --git a/vra/resource_machine.go b/vra/resource_machine.go index 0372470..8327aa0 100644 --- a/vra/resource_machine.go +++ b/vra/resource_machine.go @@ -516,8 +516,8 @@ func attachAndDetachDisks(ctx context.Context, d *schema.ResourceData, apiClient Name: diskToAttach["name"].(string), } - if v_scsi_controller, ok_scsi_controller := diskToAttach["scsi_controller"].(string); ok_scsi_controller && v_scsi_controller != "" { - if v_unit_number, ok_unit_number := diskToAttach["unit_number"].(string); ok_unit_number && v_unit_number != "" { + if vScsiController, okScsiController := diskToAttach["scsi_controller"].(string); okScsiController && vScsiController != "" { + if vUnitNumber, okUnitNumber := diskToAttach["unit_number"].(string); okUnitNumber && vUnitNumber != "" { diskAttachmentSpecification.DiskAttachmentProperties = map[string]string{"scsiController": diskToAttach["scsi_controller"].(string), "unitNumber": diskToAttach["unit_number"].(string)} } } @@ -655,8 +655,8 @@ func expandDisks(configDisks []interface{}) []*models.DiskAttachmentSpecificatio BlockDeviceID: withString(diskMap["block_device_id"].(string)), } - if v_scsi_controller, ok_scsi_controller := diskMap["scsi_controller"].(string); ok_scsi_controller && v_scsi_controller != "" { - if v_unit_number, ok_unit_number := diskMap["unit_number"].(string); ok_unit_number && v_unit_number != "" { + if vScsiController, okScsiController := diskMap["scsi_controller"].(string); okScsiController && vScsiController != "" { + if vUnitNumber, okUnitNumber := diskMap["unit_number"].(string); okUnitNumber && vUnitNumber != "" { disk.DiskAttachmentProperties = map[string]string{"scsiController": diskMap["scsi_controller"].(string), "unitNumber": diskMap["unit_number"].(string)} } }