mirror of
https://github.com/apache/cordova-android.git
synced 2025-02-01 02:12:58 +08:00
truncating file:// protocol where applicable in metadata func
This commit is contained in:
parent
b4d1ca6181
commit
79ba28d6c4
@ -755,6 +755,9 @@ public class FileUtils extends Plugin {
|
|||||||
* @throws JSONException
|
* @throws JSONException
|
||||||
*/
|
*/
|
||||||
private JSONObject getFileMetadata(String filePath) throws FileNotFoundException, JSONException {
|
private JSONObject getFileMetadata(String filePath) throws FileNotFoundException, JSONException {
|
||||||
|
if (filePath.startsWith("file://")) {
|
||||||
|
filePath = filePath.substring(7);
|
||||||
|
}
|
||||||
File file = new File(filePath);
|
File file = new File(filePath);
|
||||||
|
|
||||||
if (!file.exists()) {
|
if (!file.exists()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user