Skip to content
This repository was archived by the owner on Mar 16, 2019. It is now read-only.

Commit dd4dbb2

Browse files
committed
Merge branch '0.10.7' of github.com:wkh237/react-native-fetch-blob into 0.10.7
2 parents ed2732a + 8a75a9b commit dd4dbb2

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

android/src/main/java/com/RNFetchBlob/RNFetchBlobReq.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -148,13 +148,12 @@ public void run() {
148148
if(options.addAndroidDownloads.hasKey("path")) {
149149
req.setDestinationUri(Uri.parse("file://" + options.addAndroidDownloads.getString("path")));
150150
}
151-
// set headers
152-
ReadableMapKeySetIterator it = headers.keySetIterator();
153151
// #391 Add MIME type to the request
154152
if(options.addAndroidDownloads.hasKey("mime")) {
155153
req.setMimeType(options.addAndroidDownloads.getString("mime"));
156154
}
157-
155+
// set headers
156+
ReadableMapKeySetIterator it = headers.keySetIterator();
158157
if(options.addAndroidDownloads.hasKey("mediaScannable") && options.addAndroidDownloads.hasKey("mediaScannable") == true ) {
159158
req.allowScanningByMediaScanner();
160159
}

0 commit comments

Comments
 (0)