You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ma...@apache.org on 2012/05/11 22:43:08 UTC

android commit: Switch to using stripFileProtocol in FileUtils.notifyDelete

Updated Branches:
  refs/heads/master 6a628f7f2 -> eb66eb02c


Switch to using stripFileProtocol in FileUtils.notifyDelete


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/commit/eb66eb02
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/tree/eb66eb02
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/diff/eb66eb02

Branch: refs/heads/master
Commit: eb66eb02cb9b06a2bbc17269a8d98d9ac641a2d2
Parents: 6a628f7
Author: macdonst <si...@gmail.com>
Authored: Fri May 11 16:43:00 2012 -0400
Committer: macdonst <si...@gmail.com>
Committed: Fri May 11 16:43:00 2012 -0400

----------------------------------------------------------------------
 framework/src/org/apache/cordova/FileUtils.java |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/blob/eb66eb02/framework/src/org/apache/cordova/FileUtils.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/FileUtils.java b/framework/src/org/apache/cordova/FileUtils.java
index c8a45cb..c7d0280 100755
--- a/framework/src/org/apache/cordova/FileUtils.java
+++ b/framework/src/org/apache/cordova/FileUtils.java
@@ -220,7 +220,7 @@ public class FileUtils extends Plugin {
      * @param filePath the path to check
      */
     private void notifyDelete(String filePath) {
-        String newFilePath = filePath.substring(7);
+        String newFilePath = stripFileProtocol(filePath);
         int result = this.ctx.getContentResolver().delete(MediaStore.Images.Media.EXTERNAL_CONTENT_URI,
                 MediaStore.Images.Media.DATA + " = ?",
                 new String[] {newFilePath});