Don't include server in DM links if not needed
This commit is contained in:
parent
e6eeb9ede8
commit
c04a0a2638
5 changed files with 28 additions and 5 deletions
|
|
@ -574,7 +574,7 @@ class Util {
|
|||
}
|
||||
|
||||
sanitizeUserId(userId) {
|
||||
if (userId && userId.match(/^@.+$/)) {
|
||||
if (userId && userId.match(/^([0-9a-z-.=_/]+|@[0-9a-z-.=_/]+:.+)$/)) {
|
||||
return userId;
|
||||
}
|
||||
return null;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue