From 89d9f6124040ef6d39e5657e1c6873b997a1a21d Mon Sep 17 00:00:00 2001 From: "stephen@cubedesigners.com" Date: Wed, 7 Jun 2017 09:32:46 +0000 Subject: [PATCH] Misc code improvements to fix errors in the logs. --- inc/ws/Util/html5/class.ws.html5.php | 20 +++++++++++-------- .../html5/master/class.ws.html5.compiler.php | 3 +-- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/inc/ws/Util/html5/class.ws.html5.php b/inc/ws/Util/html5/class.ws.html5.php index dbfaba7e8..44fbb07d3 100644 --- a/inc/ws/Util/html5/class.ws.html5.php +++ b/inc/ws/Util/html5/class.ws.html5.php @@ -45,15 +45,19 @@ class wsHTML5 { public static function getPhonegapVersions() { $versions = array(); + $phonegap_dir = WS_COMPILE_ASSETS . '/_html5/js/libs/phonegap'; + + if (is_dir($phonegap_dir)) { + $dr = opendir($phonegap_dir); + while ($file = readdir($dr)) { + if ($file == '.' || $file == '..' || $file == 'plugins') { + continue; + } + $versions[] = $file; + } + usort($versions, 'version_compare'); + } - $dr = opendir(WS_COMPILE_ASSETS . '/_html5/js/libs/phonegap'); - while ($file = readdir($dr)) { - if ($file == '.' || $file == '..' || $file == 'plugins') { - continue; - } - $versions[] = $file; - } - usort($versions, 'version_compare'); return $versions; } diff --git a/inc/ws/Util/html5/master/class.ws.html5.compiler.php b/inc/ws/Util/html5/master/class.ws.html5.compiler.php index af926a146..2d0375a4c 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/master/class.ws.html5.compiler.php @@ -11,7 +11,6 @@ class wsHTML5Compiler { 'js/libs/fix/detect-zoom.js', 'js/libs/cube/fb.js', 'js/libs/cube/util.js', - 'js/libs/fastclick/fastclick.js', 'js/libs/json.js', 'js/libs/flashdetect.js', 'js/libs/screenfull.js', @@ -463,7 +462,7 @@ class wsHTML5Compiler { $this->lessFilesExtras = array_unique(array_merge($this->lessFilesExtras, $extra_files)); } - protected function writeIndex($numCSS) { + protected function writeIndex() { global $core; $html = file_get_contents($this->assets . '/_index.html'); -- 2.39.5