Page MenuHomePhorge

D8908.1765243035.diff
No OneTemporary

Size
698 B
Referenced Files
None
Subscribers
None

D8908.1765243035.diff

diff --git a/lib/shared/mention-utils.js b/lib/shared/mention-utils.js
--- a/lib/shared/mention-utils.js
+++ b/lib/shared/mention-utils.js
@@ -52,6 +52,10 @@
const chatMentionRegexString = `^(?<!\\\\)(@\\[\\[(${idSchemaRegex}):(.{1,${chatNameMaxLength}}?)(?<!\\\\)\\]\\])`;
const chatMentionRegex: RegExp = new RegExp(chatMentionRegexString);
+function encodeChatMentionText(text: string): string {
+ return text.replace(/]/g, '\\]');
+}
+
function decodeChatMentionText(text: string): string {
return text.replace(/\\]/g, ']');
}
@@ -138,5 +142,6 @@
getTypeaheadRegexMatches,
getUserMentionsCandidates,
chatMentionRegex,
+ encodeChatMentionText,
decodeChatMentionText,
};

File Metadata

Mime Type
text/plain
Expires
Tue, Dec 9, 1:17 AM (13 h, 22 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5851879
Default Alt Text
D8908.1765243035.diff (698 B)

Event Timeline