Skip to content

Commit

Permalink
fix(android): Regression breaking resolved DOM-usable file:// paths (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
breautek authored Oct 25, 2024
1 parent 17155ed commit 0150006
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/android/FileUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -1318,6 +1318,9 @@ public CordovaPluginPathHandler getPathHandler() {
io = webView.getContext().getAssets().open(fileTarget);
mimeType = getMimeType(fileUri);
} else {
if (fileUri.getScheme() == null) {
fileUri = Uri.parse(fileSystem.rootUri.getScheme() + "://" + fileUri.getPath());
}
CordovaResourceApi.OpenForReadResult resource = resourceApi.openForRead(fileUri);
io = resource.inputStream;
mimeType = resource.mimeType;
Expand Down

0 comments on commit 0150006

Please sign in to comment.