Skip to content

Commit

Permalink
fix(frontend): Avoid refreshing page on each auth state change event
Browse files Browse the repository at this point in the history
  • Loading branch information
majdyz committed Nov 20, 2024
1 parent 33dd2eb commit 072d465
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ export default function SupabaseProvider({
if (event === "SIGNED_IN") {
api.createUser();
}
router.refresh();
if (event === "SIGNED_OUT") {
router.refresh();
}
});

return () => {
Expand Down

0 comments on commit 072d465

Please sign in to comment.