From 3b593fe8c756cefbbe3e70e4f47495aa949b0614 Mon Sep 17 00:00:00 2001 From: Untone Date: Thu, 26 Sep 2024 18:21:39 +0300 Subject: [PATCH] intfix2 --- handlers/messages_routing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/handlers/messages_routing.py b/handlers/messages_routing.py index 59c2b23..46df5e3 100644 --- a/handlers/messages_routing.py +++ b/handlers/messages_routing.py @@ -46,7 +46,7 @@ async def messages_routing(msg, state): text = f"Доброе утро! Средняя токсичность твоих сообщений: {toxic_score}%" else: latest_toxic_message_id = await redis.get(f"toxic:{cid}") - scoring_msg_id = reply_msg.get("message_id") or latest_toxic_message_id + scoring_msg_id = reply_msg.get("message_id") or int(latest_toxic_message_id) toxic_score = await redis.get(f"toxic:{cid}:{uid}:{scoring_msg_id}") x = int(toxic_score) if toxic_score else 0 text = f"{x}% токсичности"