unread-fix
All checks were successful
deploy / deploy (push) Successful in 27s

This commit is contained in:
Untone 2023-10-16 18:56:03 +03:00
parent 6e0cb18909
commit faa97d27c2

View File

@ -9,7 +9,7 @@ async def get_unread_counter(chat_id: str, author_id: int) -> int:
async def get_total_unread_counter(author_id: int) -> int:
chats = await redis.execute("GET", f"chats_by_author/{author_id}")
chats = await redis.execute("SMEMBERS", f"chats_by_author/{author_id}")
unread = 0
if chats:
chats = json.loads(chats)