diff --git a/middleware.ts b/middleware.ts index c061015e..f49a5bf7 100644 --- a/middleware.ts +++ b/middleware.ts @@ -1,18 +1 @@ -import { NextResponse } from 'next/server'; -import type { NextRequest } from 'next/server'; - -export function middleware(request: NextRequest) { - const { pathname } = request.nextUrl; - if (pathname === '/lecoffre') { - const url = request.nextUrl.clone(); - url.pathname = '/lecoffre/'; - return NextResponse.redirect(url, 308); - } - return NextResponse.next(); -} - -export const config = { - matcher: ['/lecoffre'], -}; - - +// Disabled: trailing slash handled by Nginx diff --git a/next.config.js b/next.config.js index b3dbd1a9..b1c576ca 100644 --- a/next.config.js +++ b/next.config.js @@ -5,17 +5,7 @@ const nextConfig = { output: 'standalone', basePath: '/lecoffre', assetPrefix: '/lecoffre', - trailingSlash: true, - async redirects() { - return [ - { - source: '/lecoffre', - destination: '/lecoffre/', - permanent: false, - // basePath applies by default - }, - ]; - }, + trailingSlash: false, typescript: { ignoreBuildErrors: true, },