From: Florent Bruneau Date: Sun, 2 Nov 2008 16:19:13 +0000 (+0100) Subject: Minor fixes: X-Git-Tag: core/1.0.0~10 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=5640f0939025e7741d40ec18577a9aae8c2f80a5;p=platal.git Minor fixes: * Support for empty module list (gnii?) * Support for smarty path != smarty/libs/Smarty.class.php (this is debian specific) Signed-off-by: Florent Bruneau --- diff --git a/classes/platal.php b/classes/platal.php index 94d9632..a8b5459 100644 --- a/classes/platal.php +++ b/classes/platal.php @@ -50,7 +50,7 @@ abstract class Platal } $modules = func_get_args(); - if (is_array($modules[0])) { + if (isset($modules[0]) && is_array($modules[0])) { $modules = $modules[0]; } $this->path = trim(Get::_get('n', null), '/'); diff --git a/classes/plpage.php b/classes/plpage.php index 015038b..94ea220 100644 --- a/classes/plpage.php +++ b/classes/plpage.php @@ -19,7 +19,9 @@ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * ***************************************************************************/ -require_once 'smarty/libs/Smarty.class.php'; +if (!@include_once 'smarty/libs/Smarty.class.php') { + require_once 'smarty/Smarty.class.php'; +} abstract class PlPage extends Smarty {