Remove nil defaults
This commit is contained in:
parent
60b6d9ca9f
commit
5c70dd1658
|
@ -15,11 +15,8 @@ module Vagrant
|
|||
|
||||
def initialize
|
||||
@shell = "bash"
|
||||
@port = nil
|
||||
@guest_port = nil
|
||||
@forward_agent = false
|
||||
@forward_x11 = false
|
||||
@private_key_path = nil
|
||||
end
|
||||
|
||||
def forwarded_port_key=(value)
|
||||
|
|
|
@ -362,6 +362,8 @@ module Vagrant
|
|||
end
|
||||
|
||||
def ssh_port(expected_port)
|
||||
@logger.debug("Searching for SSH port: #{expected_port.inspect}")
|
||||
|
||||
# Look for the forwarded port only by comparing the guest port
|
||||
read_forwarded_ports.each do |_, _, hostport, guestport|
|
||||
return hostport if guestport == expected_port
|
||||
|
|
Loading…
Reference in New Issue