Avoid passing empty parameter

Signed-off-by: Michal Čihař <michal@cihar.com>
This commit is contained in:
Michal Čihař 2017-06-13 12:23:41 +02:00
parent 9b627d685b
commit 608f80e227
2 changed files with 4 additions and 2 deletions

View File

@ -95,14 +95,16 @@ class Menu
*/
private function _getMenu()
{
$url_params = array('db' => $this->_db);
$url_params = array();
if (strlen($this->_table) > 0) {
$tabs = $this->_getTableTabs();
$url_params['db'] = $this->_db;
$url_params['table'] = $this->_table;
$level = 'table';
} else if (strlen($this->_db) > 0) {
$tabs = $this->_getDbTabs();
$url_params['db'] = $this->_db;
$level = 'db';
} else {
$tabs = $this->_getServerTabs();

View File

@ -24,7 +24,7 @@ if (empty($viewing_mode)) {
/**
* Set parameters for links
*/
$GLOBALS['url_query'] = URL::getCommon(array('db' => $db));
$GLOBALS['url_query'] = URL::getCommon();
/**
* Defines the urls to return to in case of error in a sql statement