From 52db8210d8da63cc145270a01db8d2d1849b412a Mon Sep 17 00:00:00 2001 From: ahmedbodi Date: Mon, 10 Feb 2014 12:56:59 +0000 Subject: [PATCH] Fix Get User Call --- mining/DBInterface.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mining/DBInterface.py b/mining/DBInterface.py index 04fec8a..4fddd41 100644 --- a/mining/DBInterface.py +++ b/mining/DBInterface.py @@ -187,7 +187,10 @@ class DBInterface(): return self.dbi.list_users() def get_user(self, id): - return self.dbi.get_user(id) + if self.cache.get(id) is None: + self.cache.set(id,self.dbi.get_user(id)) + return self.cache.get(id) + def user_exists(self, username): if self.cache.get(username) is not None: