summaryrefslogtreecommitdiff
path: root/packages/backend/src/server/api
diff options
context:
space:
mode:
authorMarie <marie@kaifa.ch>2024-02-20 15:10:41 +0000
committerAmelia Yukii <amelia.yukii@shourai.de>2024-02-20 15:10:41 +0000
commit4a13508da0a5d930b4d73bb4208df39a578e7796 (patch)
tree4043fefdc93e3c66159d6a6ac565591fa25642ce /packages/backend/src/server/api
parentmerge: Warn when missing alt text (!423) (diff)
downloadsharkey-4a13508da0a5d930b4d73bb4208df39a578e7796.tar.gz
sharkey-4a13508da0a5d930b4d73bb4208df39a578e7796.tar.bz2
sharkey-4a13508da0a5d930b4d73bb4208df39a578e7796.zip
Note Edited notification type
Diffstat (limited to 'packages/backend/src/server/api')
-rw-r--r--packages/backend/src/server/api/endpoints/i/notifications-grouped.ts2
-rw-r--r--packages/backend/src/server/api/endpoints/i/notifications.ts2
2 files changed, 2 insertions, 2 deletions
diff --git a/packages/backend/src/server/api/endpoints/i/notifications-grouped.ts b/packages/backend/src/server/api/endpoints/i/notifications-grouped.ts
index 703808d279..d400cbc1c9 100644
--- a/packages/backend/src/server/api/endpoints/i/notifications-grouped.ts
+++ b/packages/backend/src/server/api/endpoints/i/notifications-grouped.ts
@@ -164,7 +164,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
groupedNotifications = groupedNotifications.slice(0, ps.limit);
const noteIds = groupedNotifications
- .filter((notification): notification is FilterUnionByProperty<MiNotification, 'type', 'mention' | 'reply' | 'quote'> => ['mention', 'reply', 'quote'].includes(notification.type))
+ .filter((notification): notification is FilterUnionByProperty<MiNotification, 'type', 'mention' | 'reply' | 'quote' | 'edited'> => ['mention', 'reply', 'quote', 'edited'].includes(notification.type))
.map(notification => notification.noteId!);
if (noteIds.length > 0) {
diff --git a/packages/backend/src/server/api/endpoints/i/notifications.ts b/packages/backend/src/server/api/endpoints/i/notifications.ts
index 52b6749e3f..d9404ea9c5 100644
--- a/packages/backend/src/server/api/endpoints/i/notifications.ts
+++ b/packages/backend/src/server/api/endpoints/i/notifications.ts
@@ -113,7 +113,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
}
const noteIds = notifications
- .filter((notification): notification is FilterUnionByProperty<MiNotification, 'type', 'mention' | 'reply' | 'quote'> => ['mention', 'reply', 'quote'].includes(notification.type))
+ .filter((notification): notification is FilterUnionByProperty<MiNotification, 'type', 'mention' | 'reply' | 'quote' | 'edited'> => ['mention', 'reply', 'quote', 'edited'].includes(notification.type))
.map(notification => notification.noteId);
if (noteIds.length > 0) {