diff options
author | Tim Smith <tsmith@chef.io> | 2018-04-27 15:38:59 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2018-04-27 15:38:59 -0700 |
commit | 011a0a5f6cf68a563781643b16601f6276a51fba (patch) | |
tree | a578112c19234995c3e37028dcdb509a70b9befd /lib/chef/resource/registry_key.rb | |
parent | a068d3cde6105a591da24d1a5ff35bde26c16214 (diff) | |
download | chef-011a0a5f6cf68a563781643b16601f6276a51fba.tar.gz |
Convert :key property in registry_key to use propertyregistry_key
Convert this to a true property. It required updating the specs a tiny bit since key gets returned as a state value now (as it should).
Signed-off-by: Tim Smith <tsmith@chef.io>
Diffstat (limited to 'lib/chef/resource/registry_key.rb')
-rw-r--r-- | lib/chef/resource/registry_key.rb | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/lib/chef/resource/registry_key.rb b/lib/chef/resource/registry_key.rb index 1ae3f81492..84abb98699 100644 --- a/lib/chef/resource/registry_key.rb +++ b/lib/chef/resource/registry_key.rb @@ -28,7 +28,6 @@ class Chef description "Use the registry_key resource to create and delete registry keys in Microsoft Windows." introduced "11.0" - identity_attr :key state_attrs :values default_action :create @@ -67,17 +66,10 @@ class Chef def initialize(name, run_context = nil) super - @key = name @values, @unscrubbed_values = [], [] end - def key(arg = nil) - set_or_return( - :key, - arg, - :kind_of => String - ) - end + property :key, String, name_property: true, identity: true def values(arg = nil) if not arg.nil? |