From 2bb4c6c08a687fdca5ff22b8ec77386d4cf4bad8 Mon Sep 17 00:00:00 2001 From: gRoussac Date: Thu, 14 Mar 2013 11:15:49 +0100 Subject: [PATCH] [-] FO : Do no try to add empty css or js file name --- classes/controller/Controller.php | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/classes/controller/Controller.php b/classes/controller/Controller.php index 9776522a2..7e4ebf6ed 100644 --- a/classes/controller/Controller.php +++ b/classes/controller/Controller.php @@ -327,15 +327,19 @@ abstract class ControllerCore foreach ($name as $plugin) { $plugin_path = Media::getJqueryPluginPath($plugin, $folder); - $this->addJS($plugin_path['js']); - $this->addCSS($plugin_path['css']); + if(!empty($plugin_path['js'])) + $this->addJS($plugin_path['js']); + if(!empty($plugin_path['css'])) + $this->addCSS($plugin_path['css']); } } else $plugin_path = Media::getJqueryPluginPath($name, $folder); - $this->addCSS($plugin_path['css']); - $this->addJS($plugin_path['js']); + if(!empty($plugin_path['css'])) + $this->addCSS($plugin_path['css']); + if(!empty($plugin_path['js'])) + $this->addJS($plugin_path['js']); } /**