refactor: update invitation

This commit is contained in:
Mauricio Siu
2025-02-16 02:57:49 -06:00
parent 4a1a14aeb4
commit e7db0ccb70
29 changed files with 270 additions and 330 deletions

View File

@@ -20,17 +20,17 @@ export type User = typeof users_temp.$inferSelect;
// };
export const findUserByAuthId = async (authId: string) => {
const userR = await db.query.user.findFirst({
where: eq(user.id, authId),
with: {},
});
if (!userR) {
throw new TRPCError({
code: "NOT_FOUND",
message: "User not found",
});
}
return userR;
// const userR = await db.query.user.findFirst({
// where: eq(user.id, authId),
// with: {},
// });
// if (!userR) {
// throw new TRPCError({
// code: "NOT_FOUND",
// message: "User not found",
// });
// }
// return userR;
};
export const findUsers = async (adminId: string) => {