summaryrefslogtreecommitdiff
path: root/lib/chef/win32/registry.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/win32/registry.rb')
-rw-r--r--lib/chef/win32/registry.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/chef/win32/registry.rb b/lib/chef/win32/registry.rb
index c0efa68464..94311f7954 100644
--- a/lib/chef/win32/registry.rb
+++ b/lib/chef/win32/registry.rb
@@ -132,6 +132,7 @@ class Chef
if has_subkeys?(key_path) && !recursive
raise Chef::Exceptions::Win32RegNoRecursive, "Registry key #{key_path} has subkeys, and recursive not specified"
end
+
hive, key_including_parent = get_hive_and_key(key_path)
# key_including_parent: Software\\Root\\Branch\\Fruit
# key => Fruit
@@ -161,6 +162,7 @@ class Chef
unless key_exists?(key_path)
raise Chef::Exceptions::Win32RegKeyMissing, "Registry key #{key_path} does not exist"
end
+
true
end
@@ -226,6 +228,7 @@ class Chef
unless value_exists?(key_path, value)
raise Chef::Exceptions::Win32RegValueMissing, "Registry key #{key_path} has no value named #{value[:name]}"
end
+
true
end
@@ -233,6 +236,7 @@ class Chef
unless data_exists?(key_path, value)
raise Chef::Exceptions::Win32RegDataMissing, "Registry key #{key_path} has no value named #{value[:name]}, containing type #{value[:type]} and data #{value[:data]}"
end
+
true
end
@@ -279,6 +283,7 @@ class Chef
if val.is_a? String
return val.downcase
end
+
val
end