Skip to content

Commit

Permalink
modify update vopt
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelkad committed Jan 23, 2024
1 parent 1bff930 commit d6959dd
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions ibm/service/power/resource_ibm_pi_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -564,9 +564,7 @@ func resourceIBMPIInstanceUpdate(ctx context.Context, d *schema.ResourceData, me
body.ServerName = name
}
if d.HasChange(PIVirtualOpticalDevice) {
if vod, ok := d.GetOk(PIVirtualOpticalDevice); ok {
body.CloudInitialization.VirtualOpticalDevice = vod.(string)
}
body.CloudInitialization.VirtualOpticalDevice = d.Get(PIVirtualOpticalDevice).(string)
}
_, err = client.Update(instanceID, body)
if err != nil {
Expand Down

0 comments on commit d6959dd

Please sign in to comment.