forked from mirror/misskey
parent
2096caf91d
commit
f0c1c08314
@ -110,7 +110,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
notifications = notifications.filter(notification => !excludeTypes.includes(notification.type));
|
notifications = notifications.filter(notification => !excludeTypes.includes(notification.type));
|
||||||
}
|
}
|
||||||
|
|
||||||
//#region Check muting & suspended
|
//#region Check muting
|
||||||
|
|
||||||
const [
|
const [
|
||||||
userIdsWhoMeMuting,
|
userIdsWhoMeMuting,
|
||||||
@ -128,12 +128,10 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
if (notifier === null) return null;
|
if (notifier === null) return null;
|
||||||
if (notifier.host && userMutedInstances.has(notifier.host)) return null;
|
if (notifier.host && userMutedInstances.has(notifier.host)) return null;
|
||||||
|
|
||||||
if (notifier.isSuspended) return null;
|
|
||||||
|
|
||||||
return notification;
|
return notification;
|
||||||
}))).filter((notification): notification is MiNotification => notification !== null);
|
}))).filter((notification): notification is MiNotification => notification !== null);
|
||||||
|
|
||||||
//#endregion Check muting & suspended
|
//#endregion Check muting
|
||||||
|
|
||||||
if (notifications.length === 0) {
|
if (notifications.length === 0) {
|
||||||
return [];
|
return [];
|
||||||
|
@ -108,7 +108,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
notifications = notifications.filter(notification => !excludeTypes.includes(notification.type));
|
notifications = notifications.filter(notification => !excludeTypes.includes(notification.type));
|
||||||
}
|
}
|
||||||
|
|
||||||
//#region Check muting & suspended
|
//#region Check muting
|
||||||
|
|
||||||
const [
|
const [
|
||||||
userIdsWhoMeMuting,
|
userIdsWhoMeMuting,
|
||||||
@ -126,12 +126,10 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
if (notifier === null) return null;
|
if (notifier === null) return null;
|
||||||
if (notifier.host && userMutedInstances.has(notifier.host)) return null;
|
if (notifier.host && userMutedInstances.has(notifier.host)) return null;
|
||||||
|
|
||||||
if (notifier.isSuspended) return null;
|
|
||||||
|
|
||||||
return notification;
|
return notification;
|
||||||
}))).filter((notification): notification is MiNotification => notification !== null);
|
}))).filter((notification): notification is MiNotification => notification !== null);
|
||||||
|
|
||||||
//#endregion Check muting & suspended
|
//#endregion Check muting
|
||||||
|
|
||||||
if (notifications.length === 0) {
|
if (notifications.length === 0) {
|
||||||
return [];
|
return [];
|
||||||
|
Loading…
Reference in New Issue
Block a user