mirror of
https://github.com/hashicorp/vagrant.git
synced 2026-06-10 17:20:16 -04:00
Update wrapper initializer to use client from manager
This commit is contained in:
parent
3d05ff7ce0
commit
0cf2ea2eb6
1 changed files with 5 additions and 8 deletions
|
|
@ -33,14 +33,11 @@ module Vagrant
|
|||
end
|
||||
|
||||
def initialize(*args, **kwargs, &block)
|
||||
info = Thread.current.thread_variable_get(:service_info)
|
||||
if info&.plugin_manager
|
||||
client = info.plugin_manager.get_plugin(
|
||||
name: self.class.plugin_name,
|
||||
type: self.class.type
|
||||
)
|
||||
kwargs[:client] = client
|
||||
end
|
||||
client = Manager.client.get_plugin(
|
||||
name: self.class.plugin_name,
|
||||
type: self.class.type
|
||||
)
|
||||
kwargs[:client] = client
|
||||
super(*args, **kwargs, &block)
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue