1
0
mirror of https://github.com/hack-chat/main.git synced 2024-03-22 13:20:33 +08:00

Merge pull request #61 from MinusGix/patch-1

Fix issue of the client not seeing disconnection if they have no myNick variable
This commit is contained in:
marzavec 2019-04-26 06:26:36 -07:00 committed by GitHub
commit f16b7b7a49
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -177,7 +177,7 @@ function pushMessage(args) {
// Message container
var messageEl = document.createElement('div');
if (args.text.includes('@' + myNick.split('#')[0] + ' ')) {
if (typeof(myNick) === 'string' && args.text.includes('@' + myNick.split('#')[0] + ' ')) {
messageEl.classList.add('refmessage');
} else {
messageEl.classList.add('message');