Browse Source

Fix

Signed-off-by: Mario Danic <mario@lovelyhq.com>
Mario Danic 7 years ago
parent
commit
158b12df71

+ 2 - 1
src/main/java/com/owncloud/android/files/services/FileUploader.java

@@ -1160,7 +1160,8 @@ public class FileUploader extends Service
         if (!uploadResult.isCancelled() &&
         if (!uploadResult.isCancelled() &&
             !ResultCode.LOCAL_FILE_NOT_FOUND.equals(uploadResult.getCode()) &&
             !ResultCode.LOCAL_FILE_NOT_FOUND.equals(uploadResult.getCode()) &&
             !uploadResult.getCode().equals(ResultCode.DELAYED_FOR_WIFI) &&
             !uploadResult.getCode().equals(ResultCode.DELAYED_FOR_WIFI) &&
-            !uploadResult.getCode().equals(ResultCode.DELAYED_FOR_CHARGING)) {
+            !uploadResult.getCode().equals(ResultCode.DELAYED_FOR_CHARGING) &&
+            !uploadResult.getCode().equals(ResultCode.LOCK_FAILED)    ) {
 
 
             int tickerId = (uploadResult.isSuccess()) ? R.string.uploader_upload_succeeded_ticker :
             int tickerId = (uploadResult.isSuccess()) ? R.string.uploader_upload_succeeded_ticker :
                     R.string.uploader_upload_failed_ticker;
                     R.string.uploader_upload_failed_ticker;

+ 1 - 1
src/main/java/com/owncloud/android/utils/FilesSyncHelper.java

@@ -174,7 +174,7 @@ public class FilesSyncHelper {
             while (cursor.moveToNext()) {
             while (cursor.moveToNext()) {
                 contentPath = cursor.getString(column_index_data);
                 contentPath = cursor.getString(column_index_data);
                 isFolder = new File(contentPath).isDirectory();
                 isFolder = new File(contentPath).isDirectory();
-                filesystemDataProvider.storeOrUpdateFileValue(cursor.getString(column_index_data),
+                filesystemDataProvider.storeOrUpdateFileValue(contentPath,
                         cursor.getLong(column_index_date_modified), isFolder, syncedFolder, dryRun);
                         cursor.getLong(column_index_date_modified), isFolder, syncedFolder, dryRun);
             }
             }
             cursor.close();
             cursor.close();