mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-08 06:55:46 +01:00
fixes #3935
This commit is contained in:
@@ -189,7 +189,7 @@ define('forum/chats', ['components', 'string', 'sounds', 'forum/infinitescroll',
|
||||
};
|
||||
|
||||
Chats.switchChat = function(uid, username) {
|
||||
if (!$('[component="chat/messages"]').length) {
|
||||
if (!$('#content [component="chat/messages"]').length) {
|
||||
return ajaxify.go('chats/' + utils.slugify(username));
|
||||
}
|
||||
|
||||
|
||||
@@ -19,10 +19,6 @@ define('chat', ['components', 'taskbar', 'string', 'sounds', 'forum/chats', 'tra
|
||||
});
|
||||
|
||||
socket.on('event:chats.receive', function(data) {
|
||||
if (ajaxify.currentPage.match(/^chats/)) {
|
||||
return;
|
||||
}
|
||||
|
||||
var username = data.message.fromUser.username;
|
||||
var isSelf = parseInt(data.message.fromUser.uid, 10) === parseInt(app.user.uid, 10);
|
||||
data.message.self = data.self;
|
||||
|
||||
Reference in New Issue
Block a user