Files
Homarr/src/middleware.ts
Thomas Camlong 1d734633f0 🚑 Merge pull request #301 from ajnart/dev
🚑 Hotfix Docker image with new NextJS version
2022-07-23 00:25:45 +02:00

16 lines
519 B
TypeScript

import { NextResponse } from 'next/server';
import type { NextRequest } from 'next/server';
// eslint-disable-next-line consistent-return
export function middleware(request: NextRequest) {
// const cookie = request.cookies.get('password');
// const isPasswordCorrect = cookie === process.env.PASSWORD;
// if (
// !isPasswordCorrect &&
// request.nextUrl.pathname !== '/login' &&
// request.nextUrl.pathname !== '/api/configs/trylogin'
// ) {
// return NextResponse.redirect('/login');
// }
}