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

Fixed regex bug in @mentions

This commit is contained in:
Roslot 2019-06-26 22:04:59 -04:00
parent 530f57cccb
commit 4e80350df5

View File

@ -316,7 +316,7 @@ function pushMessage(args) {
if ( if (
typeof (myNick) === 'string' && ( typeof (myNick) === 'string' && (
args.text.match(new RegExp('@' + myNick.split('#')[0], "gi")) || args.text.match(new RegExp('@' + myNick.split('#')[0] + '\\b', "gi")) ||
((args.type === "whisper" || args.type === "invite") && args.from) ((args.type === "whisper" || args.type === "invite") && args.from)
) )
) { ) {