mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-27 04:03:10 +02:00
fix(backend): Redisに古いMisskeyバージョンのキャッシュが残っている場合の問題を修正
This commit is contained in:
parent
5edc885c22
commit
a512915a84
1 changed files with 4 additions and 1 deletions
|
@ -80,7 +80,10 @@ export class NotificationService implements OnApplicationShutdown {
|
||||||
notifierId?: MiUser['id'] | null,
|
notifierId?: MiUser['id'] | null,
|
||||||
): Promise<MiNotification | null> {
|
): Promise<MiNotification | null> {
|
||||||
const profile = await this.cacheService.userProfileCache.fetch(notifieeId);
|
const profile = await this.cacheService.userProfileCache.fetch(notifieeId);
|
||||||
const recieveConfig = profile.notificationRecieveConfig[type];
|
|
||||||
|
// 古いMisskeyバージョンのキャッシュが残っている可能性がある
|
||||||
|
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
||||||
|
const recieveConfig = (profile.notificationRecieveConfig ?? {})[type];
|
||||||
if (recieveConfig?.type === 'never') {
|
if (recieveConfig?.type === 'never') {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue