From bc244fdc90504824b76654880898bf3f6649c299 Mon Sep 17 00:00:00 2001 From: Timothy Jaeryang Baek Date: Wed, 13 May 2026 12:44:12 +0900 Subject: [PATCH] refac --- backend/open_webui/socket/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/open_webui/socket/main.py b/backend/open_webui/socket/main.py index a3def26a7b..4217124e2b 100644 --- a/backend/open_webui/socket/main.py +++ b/backend/open_webui/socket/main.py @@ -894,7 +894,7 @@ async def _make_channel_emitter(request_info): async def get_event_emitter(request_info, update_db=True): # Channel mode: route pipeline output to channel message updates - if request_info.get('chat_id', '').startswith('channel:'): + if (request_info.get('chat_id') or '').startswith('channel:'): return await _make_channel_emitter(request_info) async def __event_emitter__(event_data): @@ -912,7 +912,7 @@ async def get_event_emitter(request_info, update_db=True): room=f'user:{user_id}', ) - if update_db and message_id and not request_info.get('chat_id', '').startswith('local:'): + if update_db and message_id and not (request_info.get('chat_id') or '').startswith('local:'): event_type = event_data.get('type') if event_type == 'status':