MCPcopy Index your code
hub / github.com/sourcebot-dev/sourcebot / onSignIn

Function onSignIn

packages/web/src/app/login/components/magicLinkForm.tsx:36–50  ·  view source on GitHub ↗
(values: z.infer<typeof magicLinkSchema>)

Source from the content-addressed store, hash-verified

34 });
35
36 const onSignIn = async (values: z.infer<typeof magicLinkSchema>) => {
37 setIsLoading(true);
38 captureEvent("wa_login_with_magic_link", {});
39
40 signIn("nodemailer", { email: values.email, redirect: false, redirectTo: callbackUrl ?? "/" })
41 .then(() => {
42 setIsLoading(false);
43
44 router.push("/login/verify?email=" + encodeURIComponent(values.email));
45 })
46 .catch((error) => {
47 console.error("Error signing in", error);
48 setIsLoading(false);
49 });
50 }
51
52 return (
53 <Form

Callers

nothing calls this directly

Calls 2

signInFunction · 0.85
captureEventFunction · 0.50

Tested by

no test coverage detected