From: David ‘Bombe’ Roden Date: Fri, 9 Dec 2011 06:40:24 +0000 (+0100) Subject: Don’t try to process non-existing images. X-Git-Tag: 0.8^2~44 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=513be9409e5d6eefa07e9d502e1e70bac4fce861;p=Sone.git Don’t try to process non-existing images. --- diff --git a/src/main/java/net/pterodactylus/sone/template/ImageLinkFilter.java b/src/main/java/net/pterodactylus/sone/template/ImageLinkFilter.java index 1684be7..a79cb0b 100644 --- a/src/main/java/net/pterodactylus/sone/template/ImageLinkFilter.java +++ b/src/main/java/net/pterodactylus/sone/template/ImageLinkFilter.java @@ -71,7 +71,8 @@ public class ImageLinkFilter implements Filter { image = core.getImage((String) data, false); } else if (data instanceof Image) { image = (Image) data; - } else { + } + if (image == null) { return null; } String imageClass = parameters.get("class");