From 5f4e902fba96832412fbab6972ca6b3ed72caaed Mon Sep 17 00:00:00 2001 From: Dany De Bontridder Date: Tue, 19 Feb 2019 20:35:26 +0100 Subject: [PATCH] Bug with javascript global variable width is undefined --- html/js/scripts.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html/js/scripts.js b/html/js/scripts.js index f1de3b0b7..37b4e95d5 100644 --- a/html/js/scripts.js +++ b/html/js/scripts.js @@ -1487,7 +1487,7 @@ function calcy(p_sy) { sy = document.documentElement.scrollTop + p_sy; } - if ( width < 801 ) { + if ( document.viewport.getDimensions().width < 801 ) { sy=sy/2; } return sy;