mirror of
https://iceshrimp.dev/crimekillz/iceshrimp-161sh.git
synced 2024-11-22 04:03:49 +01:00
refactor
This commit is contained in:
parent
f5d6d8c42a
commit
612510b2c0
@ -6,5 +6,5 @@ import { Cache } from './cache';
|
||||
const cache = new Cache<UserKeypair>(Infinity);
|
||||
|
||||
export async function getUserKeypair(userId: User['id']): Promise<UserKeypair> {
|
||||
return await cache.fetch(userId, async () => await UserKeypairs.findOneOrFail(userId));
|
||||
return await cache.fetch(userId, () => UserKeypairs.findOneOrFail(userId));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user