Skip to content
This repository has been archived by the owner on Jun 5, 2024. It is now read-only.

Add handling for additional responseType 'blob' #1028

Merged
merged 1 commit into from
Mar 18, 2022
Merged
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 changelog/unreleased/enhancement-resolve-type-blob
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Enhancement: Add blob resolveType

We now support blob as resolveType for requests in addition to text and arrayBuffer.

https://github.com/owncloud/owncloud-sdk/pull/1028
4 changes: 4 additions & 0 deletions src/helperFunctions.js
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,10 @@ class helpers {
body = await res.arrayBuffer()
break

case 'blob':
body = await res.blob()
break

default:
body = await res.text()
}
Expand Down