Partly Revert "Finished feature: Fuse on Win"

Revert changes to TemporaryMountPointChooser introduced by 598bec3050
This commit is contained in:
JaniruTEC
2020-10-13 18:30:00 +02:00
parent 598bec3050
commit 06b3343a6d

View File

@@ -69,20 +69,13 @@ public class TemporaryMountPointChooser implements MountPointChooser {
try {
switch (caller.getMountPointRequirement()) {
case PARENT_NO_MOUNT_POINT -> {
//Create everything up to the parent (but not the actual mountpoint)
Path parent = mountPoint.getParent();
Files.createDirectories(parent);
//Get the name of the parent directory (#getFileName())
//or just use the parent if the name is null (that's the case if parent is the root)
Path parentName = parent.getFileName() != null ? parent.getFileName() : parent;
LOG.debug("Successfully created/checked parent folder (\"{}\") for mount point: {}", parentName, mountPoint);
Files.createDirectories(mountPoint.getParent());
LOG.debug("Successfully created folder for mount point: {}", mountPoint);
return false;
}
case EMPTY_MOUNT_POINT -> {
//Create everything up to the mountpoint (including the actual mountpoint)
Files.createDirectories(mountPoint);
LOG.debug("Successfully created/checked mount point: {}", mountPoint);
LOG.debug("Successfully created mount point: {}", mountPoint);
return true;
}
case NONE -> {