Verified Commit 1f2b53b3 authored by Eliot Berriot's avatar Eliot Berriot
Browse files

Fixed a serialization issue

parent 64850e78
...@@ -49,7 +49,11 @@ class Redis(Backend): ...@@ -49,7 +49,11 @@ class Redis(Backend):
v = await r.get(key) v = await r.get(key)
except KeyError: except KeyError:
raise self.NotFound(key) raise self.NotFound(key)
return json.loads(v) try:
return json.loads(v)
except TypeError:
# Null, empty string, etc.
return v
async def set(self, key, value): async def set(self, key, value):
r = await self.redis() r = await self.redis()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment