equal
deleted
inserted
replaced
233 return session |
233 return session |
234 |
234 |
235 def _update_last_login_time(self, req): |
235 def _update_last_login_time(self, req): |
236 # XXX should properly detect missing permission / non writeable source |
236 # XXX should properly detect missing permission / non writeable source |
237 # and avoid "except (RepositoryError, Unauthorized)" below |
237 # and avoid "except (RepositoryError, Unauthorized)" below |
238 if req.user.metainformation()['source']['adapter'] == 'ldapuser': |
238 if req.user.cw_metainformation()['source']['adapter'] == 'ldapuser': |
239 return |
239 return |
240 try: |
240 try: |
241 req.execute('SET X last_login_time NOW WHERE X eid %(x)s', |
241 req.execute('SET X last_login_time NOW WHERE X eid %(x)s', |
242 {'x' : req.user.eid}) |
242 {'x' : req.user.eid}) |
243 req.cnx.commit() |
243 req.cnx.commit() |