diff options
author | Vasu1105 <vasundhara.jagdale@msystechnologies.com> | 2018-07-31 15:09:40 +0530 |
---|---|---|
committer | Vasu1105 <vasundhara.jagdale@msystechnologies.com> | 2018-07-31 15:09:40 +0530 |
commit | abf0deee9c83b468d5d01b321dff9d7d9cbb7b92 (patch) | |
tree | b8ae3532a8e8f748f554e9611634c5fb052248cd /lib | |
parent | 94a4b1c304c0175940a1e6cfca8043fa3ce0a97c (diff) | |
download | chef-abf0deee9c83b468d5d01b321dff9d7d9cbb7b92.tar.gz |
MSYS-872 Fix for registry key resource doesn't recognise keys when passed as attribute
Signed-off-by: Vasu1105 <vasundhara.jagdale@msystechnologies.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/chef/resource/registry_key.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/chef/resource/registry_key.rb b/lib/chef/resource/registry_key.rb index 36a6db1100..30233ddc8b 100644 --- a/lib/chef/resource/registry_key.rb +++ b/lib/chef/resource/registry_key.rb @@ -74,9 +74,12 @@ class Chef def values(arg = nil) if not arg.nil? if arg.is_a?(Hash) - @values = [ arg ] + @values = [ Mash.new(arg).symbolize_keys ] elsif arg.is_a?(Array) - @values = arg + @values = [] + arg.each do |value| + @values << Mash.new(value).symbolize_keys + end else raise ArgumentError, "Bad type for RegistryKey resource, use Hash or Array" end |