From b510c139c7b0931c1e17aeaf13b92488f4da1fd1 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Sat, 30 Oct 2021 04:37:33 +0300 Subject: Remove unused move option --- src/main/java/com/juick/service/FileSystemStorageService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/java/com') diff --git a/src/main/java/com/juick/service/FileSystemStorageService.java b/src/main/java/com/juick/service/FileSystemStorageService.java index 5b462bd7..89669283 100644 --- a/src/main/java/com/juick/service/FileSystemStorageService.java +++ b/src/main/java/com/juick/service/FileSystemStorageService.java @@ -222,7 +222,7 @@ public class FileSystemStorageService implements StorageService { String originalName = getAvatarFileName(user, ext); Path originalPath = Paths.get(avatarOriginalDir, originalName); Path tmpPath = Paths.get(tmpDir, tempFilename); - CopyOption[] copyOptions = new CopyOption[] { StandardCopyOption.REPLACE_EXISTING, StandardCopyOption.ATOMIC_MOVE }; + CopyOption[] copyOptions = new CopyOption[] { StandardCopyOption.REPLACE_EXISTING }; Files.move(tmpPath, originalPath,copyOptions); BufferedImage originalImage = ImageIO.read(originalPath.toFile()); String targetExt = "png"; -- cgit v1.2.3