Add supressed exception for more info

This commit is contained in:
Lukas Rieger (Blue) 2023-06-21 15:11:48 +02:00
parent 987015b617
commit e66838cdbc
No known key found for this signature in database
GPG Key ID: 2D09EC5ED2687FF2

View File

@ -61,7 +61,11 @@ public static void move(Path from, Path to) throws IOException {
} catch (IOException ex) {
try {
Files.move(from, to, StandardCopyOption.REPLACE_EXISTING);
} catch (FileNotFoundException | NoSuchFileException ignore) {}
} catch (FileNotFoundException | NoSuchFileException ignore) {
} catch (IOException ex2) {
ex2.addSuppressed(ex);
throw ex2;
}
}
}