summaryrefslogtreecommitdiff
path: root/lib/chef/provider/apt_preference.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/apt_preference.rb')
-rw-r--r--lib/chef/provider/apt_preference.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/chef/provider/apt_preference.rb b/lib/chef/provider/apt_preference.rb
index 59c6fc7f6d..416a1c0d1d 100644
--- a/lib/chef/provider/apt_preference.rb
+++ b/lib/chef/provider/apt_preference.rb
@@ -47,7 +47,7 @@ class Chef
# cleanup any existing pref files w/o the sanitized name (created by old apt cookbook)
if (sanitized_prefname != new_resource.package_name) && ::File.exist?("#{APT_PREFERENCE_DIR}/#{new_resource.package_name}.pref")
- Chef::Log.warn "Replacing legacy #{new_resource.package_name}.pref with #{sanitized_prefname}.pref in #{APT_PREFERENCE_DIR}"
+ logger.warn "Replacing legacy #{new_resource.package_name}.pref with #{sanitized_prefname}.pref in #{APT_PREFERENCE_DIR}"
declare_resource(:file, "#{APT_PREFERENCE_DIR}/#{new_resource.package_name}.pref") do
action :delete
end
@@ -55,7 +55,7 @@ class Chef
# cleanup any existing pref files without the .pref extension (created by old apt cookbook)
if ::File.exist?("#{APT_PREFERENCE_DIR}/#{new_resource.package_name}")
- Chef::Log.warn "Replacing legacy #{new_resource.package_name} with #{sanitized_prefname}.pref in #{APT_PREFERENCE_DIR}"
+ logger.warn "Replacing legacy #{new_resource.package_name} with #{sanitized_prefname}.pref in #{APT_PREFERENCE_DIR}"
declare_resource(:file, "#{APT_PREFERENCE_DIR}/#{new_resource.package_name}") do
action :delete
end
@@ -72,7 +72,7 @@ class Chef
sanitized_prefname = safe_name(new_resource.package_name)
if ::File.exist?("#{APT_PREFERENCE_DIR}/#{sanitized_prefname}.pref")
- Chef::Log.info "Un-pinning #{sanitized_prefname} from #{APT_PREFERENCE_DIR}"
+ logger.info "Un-pinning #{sanitized_prefname} from #{APT_PREFERENCE_DIR}"
declare_resource(:file, "#{APT_PREFERENCE_DIR}/#{sanitized_prefname}.pref") do
action :delete
end