Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
crazecoder committed Jun 4, 2019
1 parent 4d6de48 commit 10771d9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ private void startActivity() {
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP);
intent.addCategory("android.intent.category.DEFAULT");
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
intent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
String packageName = context.getPackageName();
Uri uri = FileProvider.getUriForFile(context, packageName + ".fileProvider", new File(filePath));
Expand Down

0 comments on commit 10771d9

Please sign in to comment.