diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2014-07-31 12:04:21 -0700 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2014-07-31 12:04:21 -0700 |
commit | 9a90f29b7cfd70feb5e192fb8f3a96cbe8b2c43d (patch) | |
tree | 6646d1affefc5f057752db321e3a950a4adb2f2d /lib | |
parent | 1d4809ae61fb739cff39222f223b6c3274b61740 (diff) | |
download | chef-9a90f29b7cfd70feb5e192fb8f3a96cbe8b2c43d.tar.gz |
Revert "CHEF-4028 - Log resource no longer counts as an updated resource unless a write actually happens"
This reverts commit 77119f0f37cc100d450e4f2d2f9dcfb9a57a74a8.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/chef/provider/log.rb | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/lib/chef/provider/log.rb b/lib/chef/provider/log.rb index a98ad1e1a2..1c970cc888 100644 --- a/lib/chef/provider/log.rb +++ b/lib/chef/provider/log.rb @@ -25,9 +25,6 @@ class Chef # Chef log provider, allows logging to chef's logs from recipes class ChefLog < Chef::Provider - # ordered array of the log levels - @@levels = [ :debug, :info, :warn, :error, :fatal ] - # No concept of a 'current' resource for logs, this is a no-op # # === Return @@ -42,18 +39,7 @@ class Chef # true:: Always return true def action_write Chef::Log.send(@new_resource.level, @new_resource.message) - - # resolve the integers for the current log levels - global_level = @@levels.index(Chef::Log.level) - resource_level = @@levels.index(@new_resource.level) - - # If the resource level is greater than or the same os the global - # level, then it should have been written to the log. Mark the - # resource as updated. - if resource_level >= global_level - @new_resource.updated_by_last_action(true) - end - + @new_resource.updated_by_last_action(true) end end |