if (!new File(htmlPath, mediumName).exists()) {
mediumName = image.getIcon();
}
try {
ImageInfo mediumImageInfo = new ImageInfo(htmlPath + mediumName);
ImageInfo fullInfo = new ImageInfo(htmlPath + image.getOriginal());
LorURL medURI = new LorURL(siteConfig.getMainURI(), siteConfig.getMainUrl()+mediumName);
LorURL fullURI = new LorURL(siteConfig.getMainURI(), siteConfig.getMainUrl()+image.getOriginal());
return new PreparedImage(medURI.fixScheme(secure), mediumImageInfo, fullURI.fixScheme(secure), fullInfo, image);
} catch (BadImageException e) {