add capability test before attemping to use capability

This commit is contained in:
Adam Paul 2018-03-15 11:45:42 -04:00
parent 0dc3798908
commit 2dfe520eb8
1 changed files with 3 additions and 1 deletions

View File

@ -28,7 +28,9 @@ module VagrantPlugins
error_key: :rename_computer_failed)
# Don't continue until the machine has shutdown and rebooted
machine.guest.capability(:wait_for_reboot)
if machine.guest.capability?(:wait_for_reboot)
machine.guest.capability(:wait_for_reboot)
end
end
end
end