diff --git a/web/koja/next.config.ts b/web/koja/next.config.ts index 0a19085..a864529 100644 --- a/web/koja/next.config.ts +++ b/web/koja/next.config.ts @@ -50,16 +50,11 @@ const nextConfig: NextConfig = { { protocol: "http", hostname: "**" }, ], }, - async redirects() { - return [ - // Short URL: koja.meezi.ir/my-cafe → koja.meezi.ir/fa/cafe/my-cafe - { - source: "/:slug([a-z0-9][a-z0-9-]*[a-z0-9])", - destination: "/fa/cafe/:slug", - permanent: false, - }, - ]; - }, + // NOTE: the previous "short URL" redirect (/:slug → /fa/cafe/:slug) matched + // single-segment paths INCLUDING the locale itself, so "/fa" redirected to + // "/fa/cafe/fa" (and "/en" → "/fa/cafe/en") — a non-existent slug that 500'd + // the home page. Removed; re-add via middleware with explicit reserved-word + // exclusions if short café URLs are needed. }; export default withPWA(withNextIntl(nextConfig));