Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/eager-wings-crash.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@solidjs/start": minor
---

fix onBeforeResponse
2 changes: 1 addition & 1 deletion packages/start/src/middleware/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function wrapResponseMiddleware(onBeforeResponse: ResponseMiddleware): Middlewar

const fetchEvent = getFetchEvent(h3Event);
const mwResponse = await onBeforeResponse(fetchEvent, {
body: (resp as any)?.body,
body: resp,
Copy link
Contributor

Choose a reason for hiding this comment

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

what does this change do?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

what does this change do?

that's how h3 v2 provides the body, different from h3 v1 which provided it through the .body property

});
if (mwResponse) return mwResponse;
};
Expand Down
Loading