refac
This commit is contained in:
1 parent
62b153749a
commit
b854eb09b1
1 file changed
+1
-1
@@ -1155,7 +1155,7 @@ async def search_chats(
|
|||||||
|
|
||||||
# Find a matching message snippet
|
# Find a matching message snippet
|
||||||
snippet = ''
|
snippet = ''
|
||||||
messages = chat.chat.get('history', {}).get('messages', {})
|
messages = (getattr(chat, 'chat', None) or {}).get('history', {}).get('messages', {})
|
||||||
lower_query = query.lower()
|
lower_query = query.lower()
|
||||||
|
|
||||||
for msg_id, msg in messages.items():
|
for msg_id, msg in messages.items():
|
||||||
|
|||||||
Reference in new issue
Block a user