remove redundant async from i/shared-access/list

This commit is contained in:
Hazelnoot 2025-06-21 09:08:55 -04:00
parent fa5a46f379
commit ec3947b992

View file

@ -80,11 +80,11 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
const packedUsers: Packed<'UserLite'>[] = await this.userEntityService.packMany(users, me);
const packedUserMap = new Map<string, Packed<'UserLite'>>(packedUsers.map(u => [u.id, u]));
return await Promise.all(tokens.map(async token => ({
return tokens.map(token => ({
id: token.accessTokenId,
permissions: token.accessToken!.permission,
user: packedUserMap.get(token.accessToken!.userId) as Packed<'UserLite'>,
})));
}));
});
}
}