Fix Notifications from not allowed Boards.

Thanks to FK-PATZ3 and xet7 !

Fixes #6103
This commit is contained in:
Lauri Ojansivu 2026-02-07 04:30:46 +02:00
parent d6f9626a10
commit 0a92e896f8
2 changed files with 19 additions and 15 deletions

View file

@ -387,13 +387,15 @@ Blaze.Template.registerHelper(
const currentBoard = Utils.getCurrentBoard();
if (!currentBoard)
return HTML.Raw(sanitizeHTML(content));
const knowedUsers = _.union(currentBoard.members.map(member => {
const u = ReactiveCache.getUser(member.userId);
if (u) {
member.username = u.username;
}
return member;
}), [...specialHandles]);
const knowedUsers = _.union(currentBoard.members
.filter(member => member.isActive)
.map(member => {
const u = ReactiveCache.getUser(member.userId);
if (u) {
member.username = u.username;
}
return member;
}), [...specialHandles]);
const mentionRegex = /\B@([\w.-]*)/gi;
let currentMention;