Skip to content

Commit

Permalink
add todo
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 committed Oct 3, 2024
1 parent 2b50666 commit e1589b8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/utils/body.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ export function readRawBody<E extends Encoding = "utf8">(
if (_resolved.constructor === Object) {
return Buffer.from(JSON.stringify(_resolved));
}
// TODO: Handle other BodyInit types
// https://developer.mozilla.org/en-US/docs/Web/API/Response/Response#body
if (_resolved instanceof URLSearchParams) {
return Buffer.from(_resolved.toString());

Check warning on line 96 in src/utils/body.ts

View check run for this annotation

Codecov / codecov/patch

src/utils/body.ts#L96

Added line #L96 was not covered by tests
}
Expand Down

0 comments on commit e1589b8

Please sign in to comment.