MCPcopy Create free account
hub / github.com/WardAnalytics/WardGraph / onLoginError

Function onLoginError

src/components/auth/AuthDialog.tsx:135–145  ·  view source on GitHub ↗
(error: any)

Source from the content-addressed store, hash-verified

133 * @returns void
134 */
135 const onLoginError = (error: any) => {
136 logAnalyticsEvent("login_error", { method: "email", error });
137 const errorCode = error.code;
138 if (errorCode in AuthApiErrors) {
139 setAuthApiErrorMessage(AuthApiErrors[errorCode].message);
140 } else {
141 setAuthApiErrorMessage(
142 "An error occured while logging in. Please try again later.",
143 );
144 }
145 };
146
147 /**
148 * Callback function for when the user successfully logs in with Google

Callers

nothing calls this directly

Calls 1

logAnalyticsEventFunction · 0.90

Tested by

no test coverage detected