diff --git a/services/core.py b/services/core.py index 4747a2e..3eda1f5 100644 --- a/services/core.py +++ b/services/core.py @@ -93,8 +93,10 @@ class CacheStorage: if result: CacheStorage.authors = result for a in result: - self.authors_by_user[a.user] = a - self.authors_by_id[a.id] = a + user_id = a.get("user") + author_id = a.get("id") + self.authors_by_user[user_id] = a + self.authors_by_id[author_id] = a @staticmethod async def worker():