changeset 3903:ddd05df2aced beta

added more info into __repr__ of auth user for better debugging and logging
author Marcin Kuzminski <marcin@python-works.com>
date Tue, 28 May 2013 16:21:27 +0200
parents 056827d78073
children fe053a42c4ce
files rhodecode/lib/auth.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/rhodecode/lib/auth.py	Tue May 28 16:15:40 2013 +0200
+++ b/rhodecode/lib/auth.py	Tue May 28 16:21:27 2013 +0200
@@ -445,8 +445,8 @@
             return False
 
     def __repr__(self):
-        return "<AuthUser('id:%s:%s|%s')>" % (self.user_id, self.username,
-                                              self.is_authenticated)
+        return "<AuthUser('id:%s[%s] ip:%s auth:%s')>"\
+            % (self.user_id, self.username, self.ip_addr, self.is_authenticated)
 
     def set_authenticated(self, authenticated=True):
         if self.user_id != self.anonymous_user.user_id: