friends-best/fe/lib/getUser.ts

11 lines
224 B
TypeScript
Raw Permalink Normal View History

import { prisma } from "~/server"
export const getUserByDiscordId = async (discord_id: string) => {
const user = await prisma.user.findUnique({
where: {
discord_id
}
})
return user
}