Skip to content

Commit 90ce0c4

Browse files
authored
Merge pull request #317 from ferocia/android-9-open-file
Add the FLAG_ACTIVITY_NEW_TASK flag.
2 parents 104a94e + 0b47f3d commit 90ce0c4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,8 @@ public void actionViewIntent(String path, String mime, final Promise promise) {
121121
// All the activity to be opened outside of an activity
122122
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
123123

124+
// All the activity to be opened outside of an activity
125+
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
124126
// Validate that the device can open the file
125127
PackageManager pm = getCurrentActivity().getPackageManager();
126128
if (intent.resolveActivity(pm) != null) {
@@ -411,4 +413,4 @@ public void getSDCardDir(Promise promise) {
411413
public void getSDCardApplicationDir(Promise promise) {
412414
RNFetchBlobFS.getSDCardApplicationDir(this.getReactApplicationContext(), promise);
413415
}
414-
}
416+
}

0 commit comments

Comments
 (0)