Closed jefer94 closed 1 month ago
It seems like your issue is caused by your custom middleware code that writes to pathname
before calling the middleware from next-intl
.
I'll move this to a discussion since it's a usage question and not a bug report.
Description
I have a folder called protected to views like not found, maintenance, countdown, the idea is that folder can only be accessed using rewriting, I saw that the browser got that like a redirection, why? because next-intl middleware returns a 307, causing a redirection and rendering a 404 request, I can't change that response status
Verifications
Mandatory reproduction URL
https://capyschool.com/
Reproduction description
Expected behaviour
That it don't redirect to
/es/protected/countdown
middleware
requests.ts
routing.ts
layout.tsx