From: Alan Knowles Date: Wed, 3 Jun 2020 10:08:38 +0000 (+0800) Subject: check file exists X-Git-Url: http://git.roojs.org/?p=Pman.Core;a=commitdiff_plain;h=8cd2a9237c684aa16bc21e3ac6d3793c49c65400;ds=sidebyside check file exists --- diff --git a/AssetTrait.php b/AssetTrait.php index acf584fc..5199ef26 100644 --- a/AssetTrait.php +++ b/AssetTrait.php @@ -56,7 +56,7 @@ trait Pman_Core_AssetTrait { $mtime = 0; foreach($ar as $fn) { $f = basename($fn); - if (!preg_match('/\.js$/', $f) || $fn == '.js') { // only javascript files... (so XXX.Dialog.YYY* works..) + if (!preg_match('/\.js$/', $f) || $fn == '.js' || !file_exists($dir . '/' . $f)) { // only javascript files... (so XXX.Dialog.YYY* works..) continue; } // got the 'module file..'