Skip to content

Commit

Permalink
Use mvm instead of vm
Browse files Browse the repository at this point in the history
  • Loading branch information
mjrider committed Aug 17, 2017
1 parent 995d9e8 commit f08a7d8
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions vsphere/resource_vsphere_virtual_machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -1064,10 +1064,7 @@ func resourceVSphereVirtualMachineRead(d *schema.ResourceData, meta interface{})

networkInterfaces := make([]map[string]interface{}, 0)

deviceList, err := vm.Device(context.TODO())
if err != nil {
return fmt.Errorf("failed to retrieve vm devices")
}
deviceList := object.VirtualDeviceList(mvm.Config.Hardware.Device)
deviceList = deviceList.SelectByType((*types.VirtualEthernetCard)(nil))
log.Printf("[DEBUG] Device list %+v", deviceList)
for _, device := range deviceList {
Expand Down

0 comments on commit f08a7d8

Please sign in to comment.