Skip to content

Commit

Permalink
do not ask for config from objects w/out config (#347)
Browse files Browse the repository at this point in the history
  • Loading branch information
dhgwilliam authored and swalberg committed Feb 16, 2017
1 parent f072756 commit 4acee90
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/chef/knife/base_vsphere_command.rb
Expand Up @@ -232,6 +232,7 @@ def find_network(networkName, dvswitch = nil)

if dvswitch && dvswitch != 'auto'
return networks.find do |f|
next unless f.respond_to?(:config)
sw = f.config.distributedVirtualSwitch
sw.uuid == dvswitch || sw.name == dvswitch
end
Expand Down

0 comments on commit 4acee90

Please sign in to comment.