aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/puppet/type/ssh_authorized_key.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/puppet/type/ssh_authorized_key.rb b/lib/puppet/type/ssh_authorized_key.rb
index 6b59078..5c4df53 100644
--- a/lib/puppet/type/ssh_authorized_key.rb
+++ b/lib/puppet/type/ssh_authorized_key.rb
@@ -90,10 +90,10 @@ module Puppet
def should
return super if defined?(@should) && @should[0] != :absent
- return nil unless user = resource[:user]
+ return nil unless resource[:user]
begin
- return File.expand_path("~#{user}/.ssh/authorized_keys")
+ return File.expand_path("~#{resource[:user]}/.ssh/authorized_keys")
rescue
Puppet.debug 'The required user is not yet present on the system'
return nil