From 2f638c835edf762ae6aef784f61e53f173fbf853 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Mon, 24 Apr 2017 16:35:30 +0200 Subject: [PATCH] Work-around for Safari w/ disabled cache --- wcfsetup/install/files/js/WCF.ImageViewer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wcfsetup/install/files/js/WCF.ImageViewer.js b/wcfsetup/install/files/js/WCF.ImageViewer.js index 6aace2c537..165f6f6567 100644 --- a/wcfsetup/install/files/js/WCF.ImageViewer.js +++ b/wcfsetup/install/files/js/WCF.ImageViewer.js @@ -800,8 +800,8 @@ $.widget('ui.wcfImageViewer', { var $img = new Image(); $img.src = imageData.image.url; - imageData.image.height = $img.height; - imageData.image.width = $img.width; + imageData.image.height = $img.height || $image[0].naturalHeight; + imageData.image.width = $img.width || $image[0].naturalWidth; } else { $image.css({ -- 2.20.1