Skip to content

Commit

Permalink
Merge branch 'dev-v2.27'
Browse files Browse the repository at this point in the history
  • Loading branch information
birdofpreyru committed Jun 12, 2024
2 parents 89cb169 + 3a3a5f9 commit 5454349
Show file tree
Hide file tree
Showing 14 changed files with 1,465 additions and 1,028 deletions.
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ and [old][Old Architecture] [RN][React Native] architectures.
[<img width=36 src="https://avatars.githubusercontent.com/u/10487241?s=36" />](https://github.com/Crare)

### [Contributors](https://github.com/birdofpreyru/react-native-fs/graphs/contributors)
[<img width=36 src="https://avatars.githubusercontent.com/u/10487241?s=36" />](https://github.com/Crare)
[<img width=36 src="https://avatars.githubusercontent.com/u/104437822?s=36" />](https://github.com/stetbern)
[<img width=36 src="https://avatars.githubusercontent.com/u/28300143?s=36" />](https://github.com/raphaelheinz)
[<img width=36 src="https://avatars.githubusercontent.com/u/118227615?s=36" />](https://github.com/IanOpenSpace)
Expand Down Expand Up @@ -1157,8 +1158,11 @@ in this library fork.
- `options` &mdash; [UploadFileOptionsT] &mdash; Upload settings.

- Returns an object holding `jobId` **number** (can be used to manage
in-progress download by corresponding functions) and `promise` resolving
to [UploadResultT] once the download is completed.
in-progress uploads by corresponding functions), and `promise` resolving
to [UploadResultT] once the upload completes successfully. In case the upload
fails (including when it fails due to HTTP errors), the promise is rejected
with `Error` object, to which `.result` field an instance of [UploadResultT]
is attached, if HTTP response was received.

### write()
[write()]: #write
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,11 @@ class Uploader : AsyncTask<UploadParams?, IntArray?, UploadResult>() {
}
request.flush()
request.close()
responseStream = BufferedInputStream(connection.inputStream)
if (connection.errorStream != null) {
responseStream = BufferedInputStream(connection.errorStream)
} else {
responseStream = BufferedInputStream(connection.inputStream)
}
responseStreamReader = BufferedReader(InputStreamReader(responseStream))
val responseHeaders = Arguments.createMap()
val map = connection.headerFields
Expand Down
Loading

0 comments on commit 5454349

Please sign in to comment.