KindeK
Kinde17mo ago
41 replies
wispyco

Email undefined for apple id registration on dashboard page

When a user registers and is redirected to the dashboard page after signing up I am using the following code to get the user information.

import {getKindeServerSession} from "@kinde-oss/kinde-auth-nextjs/server";

export default async function Dashboard() {


const {getUser} = getKindeServerSession();
const user = await getUser();

console.log(user);

return (<div>Dashboard<pre>{JSON.stringify(user, null, 2)}</pre></div>);
}

In the console log on the server the email is undefined.

Why may this be?
Was this page helpful?