Skip to content

Commit

Permalink
fix: fileCopyUri should include the URI schema (#527)
Browse files Browse the repository at this point in the history
BREAKING CHANGE

Make the `fileCopyUri` be an actual URI and include the schema prefix (usually `file:/`)

It already works that way on iOS
  • Loading branch information
kidroca authored Jan 19, 2022
1 parent b92916f commit 24ddad2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ public static String copyFile(Context context, Uri uri, File destFile) throws IO
}
out.close();
in.close();
return destFile.getAbsolutePath();
return destFile.toURI().toString();
} else {
throw new NullPointerException("Invalid input stream");
}
Expand Down

1 comment on commit 24ddad2

@heweitykc
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is "file://" the correct schema?

Please sign in to comment.