[Python 3] Fixed the issue loading the value for the session key from the sqlite.

This commit is contained in:
Murtuza Zabuawala
2016-03-23 12:39:23 +05:30
committed by Ashesh Vashi
parent 709311b77c
commit 12a0cb1ba1

View File

@@ -72,7 +72,7 @@ class SqliteSessionStorage(MutableMapping, SessionMixin):
rv = None rv = None
with self._get_conn() as conn: with self._get_conn() as conn:
for row in conn.execute(self._get_sql, (key,)): for row in conn.execute(self._get_sql, (key,)):
rv = loads(str(row[0])) rv = loads(bytes(row[0]))
break break
if rv is None: if rv is None:
raise KeyError('Key not in this session') raise KeyError('Key not in this session')