Skip to content

Commit

Permalink
@7.0.0 resolveLocalFileSystemURL a content uri get a FileError apache…
Browse files Browse the repository at this point in the history
  • Loading branch information
Jack committed Dec 13, 2022
1 parent 7f9a92c commit 6938f2f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/android/ContentFilesystem.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ public ContentFilesystem(Context context, CordovaResourceApi resourceApi, Cordov

@Override
public Uri toNativeUri(LocalFilesystemURL inputURL) {
String authorityAndPath = inputURL.uri.getEncodedPath().substring(this.name.length() + 2);
String encodedPath = inputURL.uri.getEncodedPath();
String authorityAndPath = encodedPath.substring(encodedPath.indexOf(this.name) + 1 + this.name.length() + 2);
if (authorityAndPath.length() < 2) {
return null;
}
Expand Down

0 comments on commit 6938f2f

Please sign in to comment.