Commit d526f21b authored by HERBERT Ryan's avatar HERBERT Ryan

controllers/notification.py fixed cache retrieval that could be NoneType

parent 0121fe63
......@@ -190,7 +190,7 @@ def get_active_notifications():
&(db.user_preference.user_id==user_id)))
query = query.find(lambda row: row.user_preference.val is None)
cached = cache.ram(key, lambda: query, time_expire=CACHE_EXPIRY)
cached = cache.ram(key, lambda: query, time_expire=0)
#TODO sanitize this response
return cached.as_json()
......
Markdown is supported
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