Skip to content

Conversation

sommeeeer
Copy link
Contributor

For #850

We should remove x-middleware-set-cookie from filteredHeaders. Instead we remove it on the overwrittenResponseHeaders which will be passed to the response.

reqProps in requestHandler.ts will use the original headers object, and pass it into processRequest. This makes sure we will see the header on initial render when using cookies().get() from Next.

Copy link

changeset-bot bot commented May 3, 2025

🦋 Changeset detected

Latest commit: a3b374d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@opennextjs/aws Patch
app-pages-router Patch
app-router Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

pkg-pr-new bot commented May 3, 2025

Open in StackBlitz

pnpm add https://pkg.pr.new/@opennextjs/aws@851

commit: a1a3504

@sommeeeer sommeeeer force-pushed the fix-middleware-setcookie branch from 09d3ec3 to 1b6eba2 Compare May 3, 2025 23:04
@sommeeeer sommeeeer requested a review from khuezy May 4, 2025 15:49
Copy link
Contributor

@khuezy khuezy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM thanks!

Copy link
Contributor

@conico974 conico974 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM Thanks

@conico974 conico974 merged commit 68a13a4 into opennextjs:main May 6, 2025
3 checks passed
@sommeeeer sommeeeer deleted the fix-middleware-setcookie branch May 6, 2025 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants