diff --git a/resolvers/stat.py b/resolvers/stat.py index 07c6bc3c..deb50b70 100644 --- a/resolvers/stat.py +++ b/resolvers/stat.py @@ -197,14 +197,13 @@ def get_with_stat(q): async def get_authors_with_stat_cached(q): - logger.debug(q) + # logger.debug(q) try: records = [] with local_session() as session: for [x] in session.execute(q): stat_str = await redis.execute('GET', f'author:{x.id}') - if isinstance(stat_str, str): - x.stat = json.loads(stat_str).get('stat') + x.stat = json.loads(stat_str).get('stat') if isinstance(stat_str, str) else {} records.append(x) except Exception as exc: raise Exception(exc)