From 346f54c10627c4cc963dc3384c7a7cbb7d12fd0f Mon Sep 17 00:00:00 2001 From: rylon Date: Fri, 16 Aug 2013 17:38:42 +0200 Subject: [PATCH] bugfix for api --- api/api.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/api/api.php b/api/api.php index 832b4b2..b6b1368 100644 --- a/api/api.php +++ b/api/api.php @@ -41,8 +41,10 @@ class api { $commands[] = array($item,$params[$item[\SYSTEM\DBD\APITable::FIELD_NAME]]); $parentid = intval($item[\SYSTEM\DBD\APITable::FIELD_ID]); } - } - + } + if(count($commands) <= 0){ + return \call_user_func(array($apiclassname,'default_page'));} + //Parameters $parameters = array(); $parentid = $commands[count($commands)-1][0];