Move up location of error message

This commit is contained in:
Brian Cain 2018-04-04 16:48:16 -07:00
parent c35e0a4f9a
commit 8451cbf854
No known key found for this signature in database
GPG Key ID: 43D51080D357A001
1 changed files with 2 additions and 1 deletions

View File

@ -227,12 +227,13 @@ module Vagrant
begin begin
prov.provision prov.provision
rescue Exception => e rescue Exception => e
@machine.ui.error(I18n.t("vagrant.errors.triggers_run_fail"))
if on_error == :halt if on_error == :halt
@logger.debug("Trigger run encountered an error. Halting on error...") @logger.debug("Trigger run encountered an error. Halting on error...")
raise e raise e
else else
@logger.debug("Trigger run encountered an error. Continuing on anyway...") @logger.debug("Trigger run encountered an error. Continuing on anyway...")
@machine.ui.error(I18n.t("vagrant.errors.triggers_run_fail"))
@machine.ui.error(e.message) @machine.ui.error(e.message)
end end
end end