From af8a603bd4821ee1228df92b28fd169ea2eee4e0 Mon Sep 17 00:00:00 2001 From: Timotej Lazar Date: Mon, 12 Oct 2015 21:18:39 +0200 Subject: Rename lang setting to gui_lang --- server/user_session.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'server') diff --git a/server/user_session.py b/server/user_session.py index b678cea..9338c2c 100644 --- a/server/user_session.py +++ b/server/user_session.py @@ -74,7 +74,7 @@ class UserSession(object): cur.execute('update codeq_user set last_login = %s where id = %s', (str(now), row[0],)) self.uid = row[0] self.username = username - self.settings = {'lang': row[5]} + self.settings = {'gui_lang': row[5]} return row[2], row[3], row[4], now else: raise AuthenticationFailed('Password mismatch') @@ -102,7 +102,7 @@ class UserSession(object): raise SignupFailed('Sign-up failed') self.uid = row[0] self.username = username - self.settings = {'lang': lang} + self.settings = {'gui_lang': lang} finally: cur.close() finally: @@ -142,7 +142,7 @@ class UserSession(object): try: cur = conn.cursor() try: - cur.execute("update codeq_user set gui_lang = %s where id = %s", (self.settings['lang'], self.uid)) + cur.execute("update codeq_user set gui_lang = %s where id = %s", (self.settings['gui_lang'], self.uid)) finally: cur.close() finally: -- cgit v1.2.1