16 lines
411 B
TypeScript
16 lines
411 B
TypeScript
'use server'
|
|
import { redirect } from "next/navigation";
|
|
import { revalidatePath } from "next/cache";
|
|
export const loginUser = async (data: any) => {
|
|
try {
|
|
const response = undefined;
|
|
// await signIn("credentials", {
|
|
// email: data.email,
|
|
// password: data.password,
|
|
// redirect: false,
|
|
// });
|
|
return response;
|
|
} catch (error) {
|
|
throw new Error(error as string);
|
|
}
|
|
}; |