mirror of
https://github.com/cryptomator/cryptomator.git
synced 2026-07-31 12:32:39 +00:00
Refactored multiple classes
Refactored UnlockWorkflow, CustomMountPointChooser, DokanyVolume and UnlockInvalidMountPointController Changed UnlockWorkflow#handleGenericError() to accept Throwables Added check for parent to CustomMountPointChooser (when using FUSE on Win) Removed legacy constant from DokanyVolume Added asserts to UnlockInvalidMountPointController and UnlockWorkflow
This commit is contained in:
+4
@@ -46,6 +46,10 @@ public class CustomMountPointChooser implements MountPointChooser {
|
||||
//This the case on Windows when using FUSE
|
||||
//See https://github.com/billziss-gh/winfsp/issues/320
|
||||
|
||||
Path parent = mountPoint.getParent();
|
||||
if (!Files.isDirectory(parent)) {
|
||||
throw wrapAsIMPE(new NotDirectoryException(parent.toString()));
|
||||
}
|
||||
//We must use #notExists() here because notExists =/= !exists (see docs)
|
||||
if (!Files.notExists(mountPoint, LinkOption.NOFOLLOW_LINKS)) {
|
||||
//File exists OR can't be determined
|
||||
|
||||
@@ -22,7 +22,6 @@ import java.util.concurrent.ExecutorService;
|
||||
public class DokanyVolume implements Volume {
|
||||
|
||||
private static final Logger LOG = LoggerFactory.getLogger(DokanyVolume.class);
|
||||
private static final int MAX_TMPMOUNTPOINT_CREATION_RETRIES = 10;
|
||||
|
||||
private static final String FS_TYPE_NAME = "Cryptomator File System";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user