Skip to content

Commit 5a22784

Browse files
committed
Fixes introduced error running vagrant hostmanager command
1 parent c621965 commit 5a22784

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

lib/vagrant-hostmanager/action/update_guest.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,14 @@ def initialize(app, env)
1111
@machine = env[:machine]
1212
@global_env = @machine.env
1313
@provider = env[:provider]
14+
15+
# config_global is deprecated from v1.5
16+
if Gem::Version.new(::Vagrant::VERSION) >= Gem::Version.new('1.5')
17+
@config = @global_env.vagrantfile.config
18+
else
19+
@config = @global_env.config_global
20+
end
21+
1422
@logger = Log4r::Logger.new('vagrant::hostmanager::update_guest')
1523
end
1624

0 commit comments

Comments
 (0)