fix: #8293, don't show error if there are no self messages

This commit is contained in:
Barış Soner Uşaklı
2020-05-05 09:42:29 -04:00
parent 6c59683b16
commit be305410fb

View File

@@ -194,6 +194,9 @@ define('forum/chats', [
if (e.target === components.get('chat/input').get(0)) {
// Retrieve message id from messages list
var message = components.get('chat/messages').find('.chat-message[data-self="1"]').last();
if (!message.length) {
return;
}
var lastMid = message.attr('data-mid');
var inputEl = components.get('chat/input');