feat: setup protected routes
This commit is contained in:
parent
77ef7038d2
commit
d43c0f78b4
2 changed files with 17 additions and 1 deletions
|
@ -3,4 +3,9 @@ import Authentik from 'next-auth/providers/authentik';
|
|||
|
||||
export const { handlers, signIn, signOut, auth } = NextAuth({
|
||||
providers: [Authentik],
|
||||
callbacks: {
|
||||
authorized: async ({ auth }) => {
|
||||
return !!auth;
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue