fix: correct condition for MEETUP_SKIP_LOGIN environment variable in middleware
This commit is contained in:
parent
6a076c0b93
commit
97ea28f588
1 changed files with 1 additions and 1 deletions
|
@ -4,7 +4,7 @@ export default auth((req) => {
|
|||
if (
|
||||
!req.auth &&
|
||||
req.nextUrl.pathname !== '/login' &&
|
||||
process.env.MEETUP_SKIP_LOGIN === 'true'
|
||||
process.env.MEETUP_SKIP_LOGIN !== 'true'
|
||||
) {
|
||||
const newUrl = new URL('/login', req.nextUrl.origin);
|
||||
return Response.redirect(newUrl);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue