💥 add basic fetch user via email

This commit is contained in:
Rafi Arrafif
2025-07-17 18:36:06 +07:00
parent ea96d160bd
commit 30806e23e0
10 changed files with 74 additions and 33 deletions

View File

@ -0,0 +1,14 @@
import { userModel } from "../../user.model";
import { getUserDataOptions } from "../../user.types";
export const findUserByEmailRepository = async (
email: string,
options: getUserDataOptions
) => {
return await userModel.findUnique({
where: {
email,
},
omit: {},
});
};