Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3513588
D6866.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1011 B
Referenced Files
None
Subscribers
None
D6866.diff
View Options
diff --git a/keyserver/src/push/send.js b/keyserver/src/push/send.js
--- a/keyserver/src/push/send.js
+++ b/keyserver/src/push/send.js
@@ -126,7 +126,7 @@
]);
const [firstNewMessageInfo, ...remainingNewMessageInfos] =
newMessageInfos;
- const threadID = firstNewMessageInfo.threadID;
+ const { threadID } = firstNewMessageInfo;
const threadInfo = threadInfos[threadID];
const updateBadge = threadInfo.currentUser.subscription.home;
@@ -136,8 +136,11 @@
username &&
threadInfo.currentUser.role &&
oldValidUsernameRegex.test(username) &&
- firstNewMessageInfo.type === messageTypes.TEXT &&
- isMentioned(username, firstNewMessageInfo.text);
+ newMessageInfos.some(
+ newMessageInfo =>
+ newMessageInfo.type === messageTypes.TEXT &&
+ isMentioned(username, newMessageInfo.text),
+ );
if (!updateBadge && !displayBanner && !userWasMentioned) {
continue;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Dec 23, 12:35 AM (18 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2693040
Default Alt Text
D6866.diff (1011 B)
Attached To
Mode
D6866: [keyserver] Check all new messages for @-mention notif override
Attached
Detach File
Event Timeline
Log In to Comment