Skip to content

Commit

Permalink
Merge pull request #45 from diggerhq/fix/login-session-refresh
Browse files Browse the repository at this point in the history
Force refresh session at the end of onboarding
  • Loading branch information
ZIJ authored Sep 13, 2024
2 parents 04acf2e + ac03bdc commit 56724d6
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { OrganizationCreation } from "./OrganizationCreation";
import { ProfileUpdate } from "./ProfileUpdate";
import { TermsAcceptance } from "./TermsAcceptance";

import { refreshSessionAction } from "@/data/user/session";
import type { Table } from "@/types";
import type { AuthUserMetadata } from "@/utils/zod-schemas/authUserMetadata";

Expand Down Expand Up @@ -48,7 +49,7 @@ export function UserOnboardingFlow({
console.log('currentStep is COMPLETE', currentStep);
console.log('onboardingStatus : ', onboardingStatus);
console.log('now redirecting to /dashboard');
router.push("/dashboard");
refreshSessionAction().then(() => { router.push("/dashboard"); });
}
}, [currentStep, router, onboardingStatus]);

Expand Down

0 comments on commit 56724d6

Please sign in to comment.