diff options
| author | Hazelnoot <acomputerdog@gmail.com> | 2025-06-05 13:16:23 -0400 |
|---|---|---|
| committer | Hazelnoot <acomputerdog@gmail.com> | 2025-06-09 11:02:36 -0400 |
| commit | 46a6612dc0e5eaa470170031012ae247f7a5eec5 (patch) | |
| tree | 126f4592c920e1ce7e13e79839e78498553e8b43 /packages/backend/src/core/UserRenoteMutingService.ts | |
| parent | add ignoreRemote filter to InternalEventService (diff) | |
| download | sharkey-46a6612dc0e5eaa470170031012ae247f7a5eec5.tar.gz sharkey-46a6612dc0e5eaa470170031012ae247f7a5eec5.tar.bz2 sharkey-46a6612dc0e5eaa470170031012ae247f7a5eec5.zip | |
convert many RedisKVCaches to QuantumKVCache or MemoryKVCache
Diffstat (limited to 'packages/backend/src/core/UserRenoteMutingService.ts')
| -rw-r--r-- | packages/backend/src/core/UserRenoteMutingService.ts | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/packages/backend/src/core/UserRenoteMutingService.ts b/packages/backend/src/core/UserRenoteMutingService.ts index bdc5e23f4b..9d5ec164c8 100644 --- a/packages/backend/src/core/UserRenoteMutingService.ts +++ b/packages/backend/src/core/UserRenoteMutingService.ts @@ -33,7 +33,7 @@ export class UserRenoteMutingService { muteeId: target.id, }); - await this.cacheService.renoteMutingsCache.refresh(user.id); + await this.cacheService.renoteMutingsCache.delete(user.id); } @bindThis @@ -44,9 +44,8 @@ export class UserRenoteMutingService { id: In(mutings.map(m => m.id)), }); - const muterIds = [...new Set(mutings.map(m => m.muterId))]; - for (const muterId of muterIds) { - await this.cacheService.renoteMutingsCache.refresh(muterId); - } + await Promise.all(Array + .from(new Set(mutings.map(m => m.muterId))) + .map(muterId => this.cacheService.renoteMutingsCache.delete(muterId))); } } |