feat(SW-467): add routing for details steps
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { NextResponse } from "next/server"
|
||||
|
||||
import { hotelReservation } from "@/constants/routes/hotelReservation"
|
||||
import { bookingFlow } from "@/constants/routes/hotelReservation"
|
||||
|
||||
import { resolve as resolveEntry } from "@/utils/entry"
|
||||
import { findLang } from "@/utils/languages"
|
||||
@@ -35,6 +35,5 @@ export const middleware: NextMiddleware = async (request) => {
|
||||
}
|
||||
|
||||
export const matcher: MiddlewareMatcher = (request) => {
|
||||
const lang = findLang(request.nextUrl.pathname)!
|
||||
return request.nextUrl.pathname.startsWith(hotelReservation[lang])
|
||||
return bookingFlow.includes(request.nextUrl.pathname)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user