You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
request.js, line 118, initializes the response to xhr.responseText before checking for an "extract" function. But the xhr.responseText getter throws an exception (in Chrome, at least) if the response type is anything other than '' or 'text', such as 'blob'. In 1.1.6, providing an extract function properly prevented mithril from calling the xhr.responseText getter.
The returned promise is fulfilled with the blob data.
Current Behavior
Browser error: "Failed to read the 'responseText' property from 'XMLHttpRequest': The value is only accessible if the object's 'responseType' is '' or 'text' (was 'blob')."
Possible Solution
Leave response uninitialized on line 118 of request.js. Set it to xhr.responseText before line 125 instead, and change line 123 to response = args.deserialize(xhr.responseText).
Environment
Browser: Chrome 71.0.3578.80 (64-bit)
The text was updated successfully, but these errors were encountered:
Mithril Version: 2.0.4rc
request.js, line 118, initializes the response to xhr.responseText before checking for an "extract" function. But the xhr.responseText getter throws an exception (in Chrome, at least) if the response type is anything other than '' or 'text', such as 'blob'. In 1.1.6, providing an extract function properly prevented mithril from calling the xhr.responseText getter.
Steps to Reproduce
Submit
Expected Behavior
The returned promise is fulfilled with the blob data.
Current Behavior
Browser error: "Failed to read the 'responseText' property from 'XMLHttpRequest': The value is only accessible if the object's 'responseType' is '' or 'text' (was 'blob')."
Possible Solution
Leave
response
uninitialized on line 118 of request.js. Set it toxhr.responseText
before line 125 instead, and change line 123 toresponse = args.deserialize(xhr.responseText)
.Environment
The text was updated successfully, but these errors were encountered: