Files
web/apps/scandic-web/middlewares/handleAuth.ts
Hrishikesh Vaipurkar 260a544c99 Merged in chore/SW-3381-move-loginbutton-to-ds- (pull request #2752)
chore(SW-3381) Moved LoginButton to design system

* chore(SW-3381) Moved LoginButton to design system


Approved-by: Anton Gunnarsson
2025-09-03 09:11:28 +00:00

14 lines
403 B
TypeScript

import { type NextMiddleware, NextResponse } from "next/server"
import { handleAuth } from "@scandic-hotels/common/constants/routes/handleAuth"
import type { MiddlewareMatcher } from "@/types/middleware"
export const middleware: NextMiddleware = () => {
return NextResponse.next()
}
export const matcher: MiddlewareMatcher = (request) => {
return handleAuth.includes(request.nextUrl.pathname)
}