We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 302690e commit d0ed3d0Copy full SHA for d0ed3d0
src/main/java/nl/esciencecenter/xenon/adaptors/filesystems/ftp/FtpFileSystem.java
@@ -312,13 +312,15 @@ protected void deleteFile(Path path) throws XenonException {
312
public boolean exists(Path path) throws XenonException {
313
314
try {
315
- if (path.isEmpty()) {
+ Path tmp = toAbsolutePath(path);
316
+
317
+ if (tmp.isEmpty()) {
318
// special case for root. We assume it always exists.
319
return true;
320
}
321
322
// otherwise, we try to get stats on the file or directory
- getFTPFileInfo(toAbsolutePath(path));
323
+ getFTPFileInfo(tmp);
324
325
} catch (NoSuchPathException e) {
326
return false;
0 commit comments