Send/Receive support for reaction read syncs
This commit is contained in:
parent
82a9705010
commit
e0c324e4ba
23 changed files with 1188 additions and 498 deletions
|
@ -60,8 +60,14 @@
|
|||
// Remove the last notification if both conditions hold:
|
||||
//
|
||||
// 1. Either `conversationId` or `messageId` matches (if present)
|
||||
// 2. `reactionFromId` matches (if present)
|
||||
removeBy({ conversationId, messageId, reactionFromId }) {
|
||||
// 2. `emoji`, `targetAuthorUuid`, `targetTimestamp` matches (if present)
|
||||
removeBy({
|
||||
conversationId,
|
||||
messageId,
|
||||
emoji,
|
||||
targetAuthorUuid,
|
||||
targetTimestamp,
|
||||
}) {
|
||||
if (!this.notificationData) {
|
||||
return;
|
||||
}
|
||||
|
@ -81,10 +87,15 @@
|
|||
return;
|
||||
}
|
||||
|
||||
const { reaction } = this.notificationData;
|
||||
if (
|
||||
reactionFromId &&
|
||||
this.notificationData.reaction &&
|
||||
this.notificationData.reaction.fromId !== reactionFromId
|
||||
reaction &&
|
||||
emoji &&
|
||||
targetAuthorUuid &&
|
||||
targetTimestamp &&
|
||||
(reaction.emoji !== emoji ||
|
||||
reaction.targetAuthorUuid !== targetAuthorUuid ||
|
||||
reaction.targetTimestamp !== targetTimestamp)
|
||||
) {
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue