diff --git a/services/cache.py b/services/cache.py index 8771229e..8ddb6949 100644 --- a/services/cache.py +++ b/services/cache.py @@ -59,7 +59,7 @@ async def update_follows_for_author( follower: Author, entity_type: str, entity: dict, is_insert: bool ): redis_key = f'author:{follower.id}:follows-{entity_type}s' - follows_str = await redis.get(redis_key) + follows_str = await redis.execute('GET', redis_key) follows = json.loads(follows_str) if follows_str else [] if is_insert: follows.append(entity) @@ -77,7 +77,7 @@ async def update_followers_for_author( follower: Author, author: Author, is_insert: bool ): redis_key = f'author:{author.id}:followers' - followers_str = await redis.get(redis_key) + followers_str = await redis.execute('GET', redis_key) followers = json.loads(followers_str) if followers_str else [] if is_insert: followers.append(follower)