diff --git a/examples/with-supertokens/pages/auth/[[...path]].tsx b/examples/with-supertokens/pages/auth/[[...path]].tsx index c6810627271..45a62ed3c2b 100644 --- a/examples/with-supertokens/pages/auth/[[...path]].tsx +++ b/examples/with-supertokens/pages/auth/[[...path]].tsx @@ -3,17 +3,19 @@ import React, { useEffect } from 'react' import styles from '../../styles/Home.module.css' import dynamic from 'next/dynamic' import SuperTokens from 'supertokens-auth-react' -import { redirectToAuth } from 'supertokens-auth-react/recipe/thirdpartyemailpassword' +import { redirectToAuth } from 'supertokens-auth-react' const SuperTokensComponentNoSSR = dynamic( - new Promise((res) => res(SuperTokens.getRoutingComponent)), + new Promise((res) => res(SuperTokens.getRoutingComponent)) as any, { ssr: false } ) export default function Auth(): JSX.Element { useEffect(() => { if (SuperTokens.canHandleRoute() === false) { - redirectToAuth() + redirectToAuth({ + redirectBack: false, + }) } }, [])