diff options
author | Simo Sorce <simo@redhat.com> | 2014-06-27 20:26:22 -0400 |
---|---|---|
committer | Patrick Uiterwijk <puiterwijk@redhat.com> | 2014-08-27 18:15:03 -0400 |
commit | 71edd1146556eecb9f9375da46313e94bf82874c (patch) | |
tree | 53588020013cf89dd0393f05e24f77f17896af01 /ipsilon/util/user.py | |
parent | 734323ca25765e6eecfa63e41b7f3ec12b084ca3 (diff) | |
download | ipsilon-71edd1146556eecb9f9375da46313e94bf82874c.tar.gz ipsilon-71edd1146556eecb9f9375da46313e94bf82874c.tar.xz ipsilon-71edd1146556eecb9f9375da46313e94bf82874c.zip |
Use new Log class everywhere
Replace copies of _debug function sprinkled all over the code
with a single implementation
Signed-off-by: Simo Sorce <simo@redhat.com>
Reviewed-by: Patrick Uiterwijk <puiterwijk@redhat.com>
- Removed replace of self._debug to self.debug
Diffstat (limited to 'ipsilon/util/user.py')
-rwxr-xr-x | ipsilon/util/user.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/ipsilon/util/user.py b/ipsilon/util/user.py index 7c53526..84f1818 100755 --- a/ipsilon/util/user.py +++ b/ipsilon/util/user.py @@ -18,6 +18,7 @@ # along with this program. If not, see <http://www.gnu.org/licenses/>. from ipsilon.util.data import Store +from ipsilon.util.log import Log import cherrypy @@ -98,14 +99,10 @@ class User(object): raise AttributeError -class UserSession(object): +class UserSession(Log): def __init__(self): self.user = self.get_data('user', 'name') - def _debug(self, fact): - if cherrypy.config.get('debug', False): - cherrypy.log(fact) - def get_user(self): return User(self.user) |