I have completed the character creation screen on the avatar branch and am preparing to merge it into main.
14 lines
294 B
TypeScript
14 lines
294 B
TypeScript
import { redirect } from "next/navigation";
|
|
|
|
import { getOnboardingRedirectPath, getSessionUser } from "@/lib/auth-helpers";
|
|
|
|
export async function LoggedInRedirect() {
|
|
const user = await getSessionUser();
|
|
|
|
if (user) {
|
|
redirect(await getOnboardingRedirectPath());
|
|
}
|
|
|
|
return null;
|
|
}
|