diff options
Diffstat (limited to 'wqflask/utility/redis_tools.py')
-rw-r--r-- | wqflask/utility/redis_tools.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/wqflask/utility/redis_tools.py b/wqflask/utility/redis_tools.py index a6c5875f..641d973e 100644 --- a/wqflask/utility/redis_tools.py +++ b/wqflask/utility/redis_tools.py @@ -28,7 +28,10 @@ def is_redis_available(): def load_json_from_redis(item_list, column_value): if type(column_value) == str: column_value = str.encode(column_value) - return json.loads(item_list[column_value]) + try: + return json.loads(item_list[column_value]) + except: + return None def get_user_id(column_name, column_value): |