summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPrajaktaPurohit <PrajaktaPurohit@users.noreply.github.com>2022-05-17 12:08:03 -0700
committerGitHub <noreply@github.com>2022-05-17 12:08:03 -0700
commit3bb7008266813ab8599f3a97980600186f41604b (patch)
treea084bbcadf2ed907a92c18947e225c434f18623f
parent63f274ed7a0289097084979dcef6a8d2c88b34ed (diff)
parenta50afd967db895e40f6f1303c32b6c9a36b0099a (diff)
downloadchef-3bb7008266813ab8599f3a97980600186f41604b.tar.gz
Merge pull request #12849 from chef/sangmeshA/INFC-130-remove_warning_from_secret_helper
Renamed private method as conflicting to inbuilt method and getting warning
-rw-r--r--lib/chef/secret_fetcher/azure_key_vault.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/chef/secret_fetcher/azure_key_vault.rb b/lib/chef/secret_fetcher/azure_key_vault.rb
index da7f0d2da5..3bbf576587 100644
--- a/lib/chef/secret_fetcher/azure_key_vault.rb
+++ b/lib/chef/secret_fetcher/azure_key_vault.rb
@@ -59,7 +59,7 @@ class Chef
end
def validate!
- raise Chef::Exceptions::Secret::ConfigurationInvalid, "You may only specify one (these are mutually exclusive): :object_id, :client_id, or :mi_res_id" if [object_id, client_id, mi_res_id].count { |x| !x.nil? } > 1
+ raise Chef::Exceptions::Secret::ConfigurationInvalid, "You may only specify one (these are mutually exclusive): :object_id, :client_id, or :mi_res_id" if [config_object_id, client_id, mi_res_id].count { |x| !x.nil? } > 1
end
private
@@ -87,7 +87,7 @@ class Chef
"https://vault.azure.net"
end
- def object_id
+ def config_object_id
config[:object_id]
end
@@ -104,7 +104,7 @@ class Chef
p = {}
p["api-version"] = api_version
p["resource"] = resource
- p["object_id"] = object_id if object_id
+ p["object_id"] = config_object_id if config_object_id
p["client_id"] = client_id if client_id
p["mi_res_id"] = mi_res_id if mi_res_id
URI.encode_www_form(p)