diff --git a/app/src/main/java/com/owncloud/android/ui/activity/UploadListActivity.java b/app/src/main/java/com/owncloud/android/ui/activity/UploadListActivity.java index d4f3d5c95094..8d5e5ac5293c 100755 --- a/app/src/main/java/com/owncloud/android/ui/activity/UploadListActivity.java +++ b/app/src/main/java/com/owncloud/android/ui/activity/UploadListActivity.java @@ -196,19 +196,22 @@ private void loadItems() { private void refresh() { backgroundJobManager.startImmediateFilesSyncJob(false, true); - // retry failed uploads - new Thread(() -> FileUploader.retryFailedUploads( - this, - uploadsStorageManager, - connectivityService, - userAccountManager, - powerManagementService)) - .start(); + if(uploadsStorageManager.getFailedUploads().length > 0){ + // retry failed uploads + new Thread(() -> FileUploader.retryFailedUploads( + this, + uploadsStorageManager, + connectivityService, + userAccountManager, + powerManagementService)) + .start(); + DisplayUtils.showSnackMessage(this, R.string.uploader_local_files_uploaded); + } + // update UI uploadListAdapter.loadUploadItemsFromDb(); swipeListRefreshLayout.setRefreshing(false); - DisplayUtils.showSnackMessage(this, R.string.uploader_local_files_uploaded); } @Override diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index ce27d03b87a0..2eca42a81088 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -915,7 +915,7 @@ Failed to start editor Add folder info creates folder info - Try to upload local files again + Retry to upload failed local files We couldnt locate the file on server. Another user may have deleted the file File not found. Are you sure that this file exists or has a previous conflict not been resolved? File upload conflict