From 1aebf6a8f3d2de8d21850487b30d3d7556a5b3b2 Mon Sep 17 00:00:00 2001 From: alperozturk Date: Wed, 25 Sep 2024 16:09:07 +0200 Subject: [PATCH] remove unnecessary autoRenameFile, ocupload already renaming, fix tests Signed-off-by: alperozturk --- .../owncloud/android/operations/UploadFileOperation.java | 8 -------- 1 file changed, 8 deletions(-) diff --git a/app/src/main/java/com/owncloud/android/operations/UploadFileOperation.java b/app/src/main/java/com/owncloud/android/operations/UploadFileOperation.java index 522825ca7e..0771bae6b7 100644 --- a/app/src/main/java/com/owncloud/android/operations/UploadFileOperation.java +++ b/app/src/main/java/com/owncloud/android/operations/UploadFileOperation.java @@ -1020,8 +1020,6 @@ public class UploadFileOperation extends SyncOperation { updateSize(size); - autoRenameFile(); - // perform the upload if (size > ChunkedFileUploadRemoteOperation.CHUNK_SIZE_MOBILE) { boolean onWifiConnection = connectivityService.getConnectivity().isWifi(); @@ -1113,12 +1111,6 @@ public class UploadFileOperation extends SyncOperation { return result; } - private void autoRenameFile() { - String newFilename = AutoRename.INSTANCE.rename(mFile.getFileName(), getCapabilities(), false); - mFile.setFileName(newFilename); - getStorageManager().saveFile(mFile); - } - private void updateSize(long size) { OCUpload ocUpload = uploadsStorageManager.getUploadById(getOCUploadId()); if (ocUpload != null) {