From faac057cca647a48333ba6be769ed4ea3253f3eb Mon Sep 17 00:00:00 2001 From: Chris Roberts Date: Wed, 17 Nov 2021 14:32:02 -0800 Subject: [PATCH] Build arguments for command via mapper directly --- plugins/commands/serve/service/command_service.rb | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/plugins/commands/serve/service/command_service.rb b/plugins/commands/serve/service/command_service.rb index fe450f6e0..eb93b9e0d 100644 --- a/plugins/commands/serve/service/command_service.rb +++ b/plugins/commands/serve/service/command_service.rb @@ -54,13 +54,14 @@ module VagrantPlugins with_info(ctx) do |info| plugin_name = info.plugin_name - ui, env, arguments = mapper.funcspec_map(req.spec, expect: [Vagrant::UI::Remote, Vagrant::Environment, SDK::Command::Arguments]) - - - # ui = Vagrant::UI::Remote.new(ui_client) - # env = Vagrant::Environment.new( - # {ui: ui, client: env_client} - # ) + _, env, arguments = mapper.funcspec_map( + req.spec, + expect: [ + Vagrant::UI::Remote, + Vagrant::Environment, + SDK::Command::Arguments + ] + ) plugin = Vagrant::Plugin::V2::Plugin.manager.commands[plugin_name.to_sym].to_a.first if !plugin