diff options
Diffstat (limited to 'lib/chef/property.rb')
-rw-r--r-- | lib/chef/property.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/chef/property.rb b/lib/chef/property.rb index c26146a96b..24dbd56f2c 100644 --- a/lib/chef/property.rb +++ b/lib/chef/property.rb @@ -130,6 +130,7 @@ class Chef if options.key?(:name_property) raise ArgumentError, "name_attribute and name_property are functionally identical and both cannot be specified on a property at once. Use just one on property #{self}" end + # replace name_property with name_attribute in place options = Hash[options.map { |k, v| k == :name_attribute ? [ :name_property, v ] : [ k, v ] }] @options = options @@ -230,6 +231,7 @@ class Chef def default return options[:default] if options.key?(:default) return Chef::DelayedEvaluator.new { name } if name_property? + nil end @@ -260,6 +262,7 @@ class Chef # def desired_state? return true if !options.key?(:desired_state) + options[:desired_state] end |