##// END OF EJS Templates
ssh: prevent exceptions when user associated to stored old key is not found.
marcink -
r2206:68955e56 default
parent child Browse files
Show More
@@ -180,6 +180,11 b' class SshWrapper(object):'
180
180
181 elif scm_detected:
181 elif scm_detected:
182 user = User.get(user_id)
182 user = User.get(user_id)
183 if not user:
184 log.warning('User with id %s not found', user_id)
185 exit_code = -1
186 return exit_code
187
183 auth_user = user.AuthUser()
188 auth_user = user.AuthUser()
184 permissions = auth_user.permissions['repositories']
189 permissions = auth_user.permissions['repositories']
185
190
@@ -83,8 +83,9 b' class VcsServer(object):'
83 self.user, self.repo_name)
83 self.user, self.repo_name)
84 return 0
84 return 0
85
85
86 log.error('Cannot properly fetch or allow user permissions. '
86 log.error('Cannot properly fetch or allow user %s permissions. '
87 'Return value is: %s, req action: %s', permission, action)
87 'Return value is: %s, req action: %s',
88 self.user, permission, action)
88 return -2
89 return -2
89
90
90 def update_environment(self, action, extras=None):
91 def update_environment(self, action, extras=None):
General Comments 0
You need to be logged in to leave comments. Login now