diff --git a/src/main/java/de/mattv/fileserver/data/Node.java b/src/main/java/de/mattv/fileserver/data/Node.java index 7418e07..7831b5a 100644 --- a/src/main/java/de/mattv/fileserver/data/Node.java +++ b/src/main/java/de/mattv/fileserver/data/Node.java @@ -49,8 +49,9 @@ public class Node { .allowOverwrite(true) .outputFormat("png") .toFile(previewFile); - } catch (UnsupportedFormatException ignored) {} - - hasPreview = true; + hasPreview = true; + } catch (UnsupportedFormatException | IllegalStateException ignored) { + hasPreview = false; + } } }