Skip to content

Commit

Permalink
Fix other case for buildId mismatch (#53643)
Browse files Browse the repository at this point in the history
Continues fix from #53596 and
applies it for the `x-matched-path` specific code path.
  • Loading branch information
ijjk authored Aug 6, 2023
1 parent 3e637ca commit bb380e7
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions packages/next/src/server/base-server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -926,6 +926,16 @@ export default abstract class Server<ServerOptions extends Options = Options> {
}
parsedUrl.pathname = matchedPath
url.pathname = parsedUrl.pathname

const normalizeResult = await this.normalizeNextData(
req,
res,
parsedUrl
)

if (normalizeResult.finished) {
return
}
} catch (err) {
if (err instanceof DecodeError || err instanceof NormalizeError) {
res.statusCode = 400
Expand Down

0 comments on commit bb380e7

Please sign in to comment.