X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/35ace0b97335cdb8d45b5b2be94c41e17fe9e040..890bf7fa51135aa24e07ab8d02c002b22a66716a:/src/eu/alefzero/owncloud/datamodel/FileDataStorageManager.java diff --git a/src/eu/alefzero/owncloud/datamodel/FileDataStorageManager.java b/src/eu/alefzero/owncloud/datamodel/FileDataStorageManager.java index 0e527850..0ad0d1bb 100644 --- a/src/eu/alefzero/owncloud/datamodel/FileDataStorageManager.java +++ b/src/eu/alefzero/owncloud/datamodel/FileDataStorageManager.java @@ -59,8 +59,8 @@ public class FileDataStorageManager implements DataStorageManager { OCFile file = null; if (c.moveToFirst()) { file = createFileInstance(c); - c.close(); } + c.close(); return file; } @@ -70,8 +70,8 @@ public class FileDataStorageManager implements DataStorageManager { OCFile file = null; if (c.moveToFirst()) { file = createFileInstance(c); - c.close(); } + c.close(); return file; } @@ -288,9 +288,9 @@ public class FileDataStorageManager implements DataStorageManager { file.setStoragePath(c.getString(c .getColumnIndex(ProviderTableMeta.FILE_STORAGE_PATH))); if (file.getStoragePath() == null) { - // try to find exisiting file and bind it with current account + // try to find existing file and bind it with current account File sdCard = Environment.getExternalStorageDirectory(); - File f = new File(sdCard.getAbsolutePath() + "/owncloud/" + mAccount.name + file.getRemotePath()); + File f = new File(sdCard.getAbsolutePath() + "/owncloud/" + mAccount.name + file.getURLDecodedRemotePath()); if (f.exists()) file.setStoragePath(f.getAbsolutePath()); }