Skip to content

fix: support TypedArray and DataView as Request body#1472

Merged
mcollina merged 2 commits intonodejs:mainfrom
LiviaMedeiros:fix-request-arraybufferview
Jun 1, 2022
Merged

fix: support TypedArray and DataView as Request body#1472
mcollina merged 2 commits intonodejs:mainfrom
LiviaMedeiros:fix-request-arraybufferview

Conversation

@LiviaMedeiros
Copy link
Copy Markdown
Member

  • ArrayBuffer.isView(BufferInstance) didn't allow isBuffer() branch to be reached
  • Fixed DataView dropping whole buffer into request body
  • Fixed the rest of ArrayBufferViews

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented May 31, 2022

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.74%. Comparing base (4711982) to head (c698a3f).
⚠️ Report is 1968 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1472      +/-   ##
==========================================
+ Coverage   94.70%   94.74%   +0.04%     
==========================================
  Files          49       49              
  Lines        4246     4246              
==========================================
+ Hits         4021     4023       +2     
+ Misses        225      223       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@LiviaMedeiros LiviaMedeiros force-pushed the fix-request-arraybufferview branch from 8fd381d to c698a3f Compare June 1, 2022 04:16
Copy link
Copy Markdown
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@mcollina mcollina merged commit 48c03b6 into nodejs:main Jun 1, 2022
KhafraDev pushed a commit to KhafraDev/undici that referenced this pull request Jun 23, 2022
* fix: support `TypedArray` and `DataView` as Request body

* test: test `TypedArray` and `DataView` as Request body
metcoder95 pushed a commit to metcoder95/undici that referenced this pull request Dec 26, 2022
* fix: support `TypedArray` and `DataView` as Request body

* test: test `TypedArray` and `DataView` as Request body
crysmags pushed a commit to crysmags/undici that referenced this pull request Feb 27, 2024
* fix: support `TypedArray` and `DataView` as Request body

* test: test `TypedArray` and `DataView` as Request body
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