diff --git a/ChatServiceApp/js_views.py b/ChatServiceApp/js_views.py index aaa7988..318bffb 100644 --- a/ChatServiceApp/js_views.py +++ b/ChatServiceApp/js_views.py @@ -61,7 +61,7 @@ def update_chat_ajax(request): tpl_name = 'blocks/profile/b_messages_container.html' - if 'ticket_id' in data: + if 'ticket_id' in data and data['ticket_id']: ticket = MsgGroup.objects.get(id=data['ticket_id']) sender = User.objects.get(id=data['sender'])