summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/chef/resource/macos_userdefaults.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/chef/resource/macos_userdefaults.rb b/lib/chef/resource/macos_userdefaults.rb
index ce253734b4..b0b9c32fe0 100644
--- a/lib/chef/resource/macos_userdefaults.rb
+++ b/lib/chef/resource/macos_userdefaults.rb
@@ -118,7 +118,7 @@ class Chef
action :write, description: "Write the value to the specified domain/key." do
converge_if_changed do
Chef::Log.debug("Updating defaults value for #{new_resource.key} in #{new_resource.domain}")
- set_preference(new_resource)
+ CF::Preferences.set!(new_resource.key, new_resource.value, new_resource.domain, new_resource.user, new_resource.host)
end
end
@@ -136,10 +136,6 @@ class Chef
CF::Preferences.get(new_resource.key, new_resource.domain, new_resource.user, new_resource.host)
end
- def set_preference(new_resource)
- CF::Preferences.set!(new_resource.key, new_resource.value, new_resource.domain, new_resource.user, new_resource.host)
- end
-
# Return valid hostname based on the input from host property
def to_cf_host(value)
case value