This commit is contained in:
parent
0ff83c60f4
commit
8ed276c1b8
@ -30,7 +30,9 @@ class Redis:
|
||||
async def get(self, key, loads=True):
|
||||
"""Get a specific key."""
|
||||
if loads:
|
||||
return json.loads(await self._redis.get(key))
|
||||
value = await self._redis.get(key)
|
||||
if value:
|
||||
return json.loads(value)
|
||||
return await self._redis.get(key)
|
||||
|
||||
async def close(self):
|
||||
|
Loading…
Reference in New Issue
Block a user