mirror of
https://github.com/cryptomator/cryptomator.git
synced 2026-05-21 20:21:27 +00:00
get rid of RevealException
This commit is contained in:
@@ -8,7 +8,6 @@ import org.cryptomator.cryptofs.CryptoFileSystem;
|
||||
import org.cryptomator.frontend.dokany.Mount;
|
||||
import org.cryptomator.frontend.dokany.MountFactory;
|
||||
import org.cryptomator.frontend.dokany.MountFailedException;
|
||||
import org.cryptomator.frontend.dokany.RevealException;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
@@ -53,22 +52,11 @@ public class DokanyVolume extends AbstractVolume {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reveal(RevealerFacade r) throws VolumeException {
|
||||
public void reveal(RevealerFacade revealer) throws VolumeException {
|
||||
try {
|
||||
mount.reveal(p -> {
|
||||
try {
|
||||
r.reveal(p);
|
||||
} catch (VolumeException e) {
|
||||
throw new RevealException(e);
|
||||
}
|
||||
});
|
||||
} catch (RevealException e) {
|
||||
LOG.debug("Revealing the vault in file manger failed: " + e.getMessage());
|
||||
if (e.getCause() instanceof VolumeException) {
|
||||
throw (VolumeException) e.getCause();
|
||||
} else {
|
||||
throw new VolumeException(e);
|
||||
}
|
||||
mount.reveal(revealer::reveal);
|
||||
} catch (Exception e) {
|
||||
throw new VolumeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -12,7 +12,6 @@ import org.cryptomator.frontend.fuse.mount.FuseMountFactory;
|
||||
import org.cryptomator.frontend.fuse.mount.FuseNotSupportedException;
|
||||
import org.cryptomator.frontend.fuse.mount.Mount;
|
||||
import org.cryptomator.frontend.fuse.mount.Mounter;
|
||||
import org.cryptomator.frontend.fuse.mount.RevealException;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
@@ -73,22 +72,11 @@ public class FuseVolume extends AbstractVolume {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reveal(RevealerFacade r) throws VolumeException {
|
||||
public void reveal(RevealerFacade revealer) throws VolumeException {
|
||||
try {
|
||||
mount.reveal(p -> {
|
||||
try {
|
||||
r.reveal(p);
|
||||
} catch (VolumeException e) {
|
||||
throw new RevealException(e);
|
||||
}
|
||||
});
|
||||
} catch (RevealException e) {
|
||||
LOG.debug("Revealing the vault in file manger failed: " + e.getMessage());
|
||||
if (e.getCause() instanceof VolumeException) {
|
||||
throw (VolumeException) e.getCause();
|
||||
} else {
|
||||
throw new VolumeException(e);
|
||||
}
|
||||
mount.reveal(revealer::reveal);
|
||||
} catch (Exception e) {
|
||||
throw new VolumeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -73,22 +73,11 @@ public class WebDavVolume implements Volume {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reveal(RevealerFacade r) throws VolumeException {
|
||||
public void reveal(RevealerFacade revealer) throws VolumeException {
|
||||
try {
|
||||
mount.reveal(p -> {
|
||||
try {
|
||||
r.reveal(p);
|
||||
} catch (VolumeException e) {
|
||||
throw new Mounter.RevealException(e);
|
||||
}
|
||||
});
|
||||
} catch (Mounter.RevealException e) {
|
||||
LOG.debug("Revealing the vault in file manger failed: " + e.getMessage());
|
||||
if (e.getCause() instanceof VolumeException) {
|
||||
throw (VolumeException) e.getCause();
|
||||
} else {
|
||||
throw new VolumeException(e);
|
||||
}
|
||||
mount.reveal(revealer::reveal);
|
||||
} catch (Exception e) {
|
||||
throw new VolumeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -29,9 +29,9 @@
|
||||
<cryptomator.integrations.win.version>0.2.1</cryptomator.integrations.win.version>
|
||||
<cryptomator.integrations.mac.version>0.1.0-beta3</cryptomator.integrations.mac.version>
|
||||
<cryptomator.integrations.linux.version>0.1.0-beta2</cryptomator.integrations.linux.version>
|
||||
<cryptomator.fuse.version>1.2.7</cryptomator.fuse.version>
|
||||
<cryptomator.dokany.version>1.2.2</cryptomator.dokany.version>
|
||||
<cryptomator.webdav.version>1.1.0</cryptomator.webdav.version>
|
||||
<cryptomator.fuse.version>1.2.8</cryptomator.fuse.version>
|
||||
<cryptomator.dokany.version>1.2.3</cryptomator.dokany.version>
|
||||
<cryptomator.webdav.version>1.1.1</cryptomator.webdav.version>
|
||||
|
||||
<!-- 3rd party dependencies -->
|
||||
<javafx.version>15</javafx.version>
|
||||
|
||||
Reference in New Issue
Block a user