summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-01-05 11:59:57 -0800
committerGitHub <noreply@github.com>2018-01-05 11:59:57 -0800
commit90b263b605387f056e0754888e44475114823102 (patch)
treed35aaa663165805957120b07959156b8751fd3b9 /lib
parentaaf0aa51823346d81b6baa4e5770d769f5412a4e (diff)
parent3f54ed4ddfc6f394906cc160ebff2e41448fbd4e (diff)
downloadchef-90b263b605387f056e0754888e44475114823102.tar.gz
Merge pull request #6735 from get9/fix-dscl-home-exists
Check for set home property before file existence (fixes #5777)
Diffstat (limited to 'lib')
-rw-r--r--lib/chef/provider/user/dscl.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/provider/user/dscl.rb b/lib/chef/provider/user/dscl.rb
index 60167856d1..bc865b17c5 100644
--- a/lib/chef/provider/user/dscl.rb
+++ b/lib/chef/provider/user/dscl.rb
@@ -318,7 +318,7 @@ user password using shadow hash.")
end
def current_home_exists?
- ::File.exist?(current_resource.home)
+ !!current_resource.home && ::File.exist?(current_resource.home)
end
def new_home_exists?