mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-11 00:15:46 +01:00
closes #716, also moved chat to its own template
This commit is contained in:
@@ -391,14 +391,16 @@ var socket,
|
||||
}
|
||||
|
||||
require(['chat'], function (chat) {
|
||||
var chatModal;
|
||||
if (!chat.modalExists(touid)) {
|
||||
chatModal = chat.createModal(username, touid);
|
||||
chat.createModal(username, touid, loadAndCenter);
|
||||
} else {
|
||||
chatModal = chat.getModal(touid);
|
||||
loadAndCenter(chat.getModal(touid));
|
||||
}
|
||||
|
||||
function loadAndCenter(chatModal) {
|
||||
chat.load(chatModal.attr('UUID'));
|
||||
chat.center(chatModal);
|
||||
}
|
||||
chat.load(chatModal.attr('UUID'));
|
||||
chat.center(chatModal);
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user