WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
171489
Response.blob() has empty type when created with a ReadableStream and content-type header
https://bugs.webkit.org/show_bug.cgi?id=171489
Summary
Response.blob() has empty type when created with a ReadableStream and content...
Ben Kelly
Reported
2017-04-30 19:31:33 PDT
WebKit is currently failing this WPT test: fetch/api/response/response-consume.html On the "from stream to blob" case. This test is basically: var data = 'hello world'; var stream = new ReadableStream({ start: function(controller) { controller.enqueue(stringToArray(data)); controller.close(); } }); var r = new Response(stream, { headers: [['content-type', 'text/plain']] }); r.blob().then(b => assert_equals(b.type, 'text/plain')); WebKit is failing because whenever a ReadableStream is passed as the body of the Response the blob() output will have an empty string Blob.type.
Attachments
Set Response.blob() type correctly when body is a ReadableStream.
(4.06 KB, patch)
2017-04-30 19:44 PDT
,
Ben Kelly
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Ben Kelly
Comment 1
2017-04-30 19:44:43 PDT
Created
attachment 308708
[details]
Set Response.blob() type correctly when body is a ReadableStream.
youenn fablet
Comment 2
2017-05-02 09:29:45 PDT
Comment on
attachment 308708
[details]
Set Response.blob() type correctly when body is a ReadableStream. Thanks!
WebKit Commit Bot
Comment 3
2017-05-02 09:58:37 PDT
Comment on
attachment 308708
[details]
Set Response.blob() type correctly when body is a ReadableStream. Clearing flags on attachment: 308708 Committed
r216073
: <
http://trac.webkit.org/changeset/216073
>
WebKit Commit Bot
Comment 4
2017-05-02 09:58:38 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug