chore: fix all linting issues and optimize components
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 32s
Build & Deploy / 🧪 QA (push) Failing after 1m19s
Build & Deploy / 🏗️ Build (push) Has been skipped
Build & Deploy / 🚀 Deploy (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 1s

This commit is contained in:
2026-02-11 10:40:57 +01:00
parent a12759d507
commit c111efae1a
23 changed files with 275 additions and 59 deletions

View File

@@ -1,5 +1,5 @@
import createMiddleware from 'next-intl/middleware';
import { NextResponse, NextRequest } from 'next/server';
import { NextRequest } from 'next/server';
// Create the internationalization middleware
const intlMiddleware = createMiddleware({
@@ -30,7 +30,7 @@ export default function middleware(request: NextRequest) {
// Prioritize x-forwarded-host (passed by Traefik) over the local Host header
const hostHeader =
headers.get('x-forwarded-host') || headers.get('host') || 'testing.klz-cables.com';
const [publicHostname] = hostHeader.split(':');
hostHeader.split(':');
urlObj.protocol = proto;
// urlObj.hostname = publicHostname; // Don't rewrite hostname yet as it breaks internal fetches in dev