From 8efc8542b7c98b718cb63d0e56291dc619c11ef8 Mon Sep 17 00:00:00 2001 From: sophia Date: Tue, 24 Aug 2021 13:45:45 -0500 Subject: [PATCH] Rename guest client 'capability method to match the client interface --- lib/vagrant/guest/remote.rb | 4 ++-- plugins/commands/serve/client/guest.rb | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/vagrant/guest/remote.rb b/lib/vagrant/guest/remote.rb index a817b6fd8..68913f42a 100644 --- a/lib/vagrant/guest/remote.rb +++ b/lib/vagrant/guest/remote.rb @@ -40,7 +40,7 @@ module Vagrant # @param [Symbol] cap_name Name of the capability def capability(cap_name, *args) @logger.debug("running remote guest capability #{cap_name} with args #{args}") - if !client.capability?(cap_name) + if !client.has_capability?(cap_name) raise Errors::GuestCapabilityNotFound, cap: cap_name.to_s, guest: name @@ -54,7 +54,7 @@ module Vagrant # @return [Boolean] def capability?(cap_name) @logger.debug("checking for remote guest capability #{cap_name}") - client.capability?(cap_name) + client.has_capability?(cap_name) end # Returns the specified or detected guest type name. diff --git a/plugins/commands/serve/client/guest.rb b/plugins/commands/serve/client/guest.rb index 33db0f20a..870374ec2 100644 --- a/plugins/commands/serve/client/guest.rb +++ b/plugins/commands/serve/client/guest.rb @@ -37,7 +37,7 @@ module VagrantPlugins # @param [Symbol] cap_name Capability name # @return [Boolean] - def capability?(cap_name) + def has_capability?(cap_name) @logger.debug("checking for capability #{cap_name}") val = SDK::Args::NamedCapability.new(Capability: cap_name.to_s) req = SDK::FuncSpec::Args.new(