summaryrefslogtreecommitdiff
path: root/lib/chef/provider/user/dscl.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/provider/user/dscl.rb')
-rw-r--r--lib/chef/provider/user/dscl.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/provider/user/dscl.rb b/lib/chef/provider/user/dscl.rb
index 2a7300c017..7b266b8d62 100644
--- a/lib/chef/provider/user/dscl.rb
+++ b/lib/chef/provider/user/dscl.rb
@@ -584,7 +584,7 @@ in 'password', with the associated 'salt' and 'iterations'.")
#
def run_dscl(*args)
- result = shell_out("dscl", ".", "-#{args[0]}", args[1..-1])
+ result = shell_out("dscl", ".", "-#{args[0]}", args[1..])
return "" if ( args.first =~ /^delete/ ) && ( result.exitstatus != 0 )
raise(Chef::Exceptions::DsclCommandFailed, "dscl error: #{result.inspect}") unless result.exitstatus == 0
raise(Chef::Exceptions::DsclCommandFailed, "dscl error: #{result.inspect}") if result.stdout.include?("No such key: ")
@@ -593,7 +593,7 @@ in 'password', with the associated 'salt' and 'iterations'.")
end
def run_plutil(*args)
- result = shell_out("plutil", "-#{args[0]}", args[1..-1])
+ result = shell_out("plutil", "-#{args[0]}", args[1..])
raise(Chef::Exceptions::PlistUtilCommandFailed, "plutil error: #{result.inspect}") unless result.exitstatus == 0
if result.stdout.encoding == Encoding::ASCII_8BIT