Просмотр исходного кода

hide error on TableAcl::getRootTableName - bug in login page

Piotr Labudda 9 лет назад
Родитель
Сommit
6c7262ea38
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      SE/se-lib/TableAcl.php

+ 2 - 2
SE/se-lib/TableAcl.php

@@ -46,7 +46,7 @@ class TableAcl extends Core_AclBase {
 	public function getSourceName() { return 'default_db'; }
 	public function getName() { return $this->_name; }
 	public function getRootTableName() {
-		if (empty($this->_name)) throw new Exception("Table name not defined");
+		if (empty($this->_name)) return null;// throw new Exception("Table name not defined");
 		if ($this->_rootTableName) return $this->_rootTableName;
 		$dbName = DB::getPDO()->getDatabaseName();
 		$this->_rootTableName = DB::getPDO()->fetchValue("
@@ -55,7 +55,7 @@ class TableAcl extends Core_AclBase {
 			where t.TABLE_SCHEMA = '{$dbName}'
 				and t.TABLE_NAME LIKE '{$this->_name}'
 		");
-		if (!$this->_rootTableName) throw new Exception("Table '{$this->_name}' not exists!");
+		if (!$this->_rootTableName) return null;// throw new Exception("Table '{$this->_name}' not exists!");
 		DBG::log("TableAcl({$this->_zasobID})->getRootTableName (\$this->_name='{$this->_name}', \$this->_rootTableName='{$this->_rootTableName}')");
 		if ($this->_rootTableName != $this->_name) {
 			if ($this->_zasobID) {