1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

fix(messages): Fix broken sanitized name for notifications/alert messages

* Note that this fix will not take effect until the message processor is
hooked up to widget and chatform
This commit is contained in:
Mick Sayson 2019-06-18 17:26:47 -07:00
parent f0d840002a
commit fef89d70f9

View File

@ -26,7 +26,7 @@ void MessageProcessor::SharedParams::onUserNameSet(const QString& username)
QString sanename = username;
sanename.remove(QRegExp("[\\t\\n\\v\\f\\r\\x0000]"));
nameMention = QRegExp("\\b" + QRegExp::escape(username) + "\\b", Qt::CaseInsensitive);
sanitizedNameMention = nameMention;
sanitizedNameMention = QRegExp("\\b" + QRegExp::escape(sanename) + "\\b", Qt::CaseInsensitive);
}
MessageProcessor::MessageProcessor(const MessageProcessor::SharedParams& sharedParams)