MCPcopy Index your code
hub / github.com/CodebuffAI/codebuff / lookupUserByEmail

Function lookupUserByEmail

scripts/grant-credits.ts:14–21  ·  view source on GitHub ↗
(email: string)

Source from the content-addressed store, hash-verified

12}
13
14async function lookupUserByEmail(email: string) {
15 const [user] = await db
16 .select({ id: schema.user.id, email: schema.user.email, name: schema.user.name })
17 .from(schema.user)
18 .where(eq(schema.user.email, email.toLowerCase()))
19 .limit(1)
20 return user ?? null
21}
22
23async function lookupUserById(userId: string) {
24 const [user] = await db

Callers 1

mainFunction · 0.85

Calls 1

fromMethod · 0.80

Tested by

no test coverage detected