lgtm

One PR. One bug.
Find the line.

Open today's case

A new case every day · TypeScript · free, no sign up

case #41src/auth/permissions.ts
5+// can() runs 5 to 10 times per request, so keep the roles for the life of the request.
6+export async function getPermissions(roles: RolesTable, req: Request, userId: string) {
7+ const key = `permissions:${req.orgId}`;
8+
9+ const cached = req.cache.get(key);
10+ if (cached) return cached;
Case closed

Open the case, accuse the line a good reviewer would flag, then see the proof.

lgtm, made for code reviewersGitHub