From cfc56a6241e115ffdc9714387c880c826a97a867 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Tue, 15 Jul 2014 11:07:50 +0000 Subject: [PATCH] fixed PHP Fatal error: Call to a member function MetaTables() on a non-object, when non-default apps like esyncpro got installed/updated --- phpgwapi/inc/class.db_backup.inc.php | 1 + phpgwapi/inc/class.schema_proc.inc.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/phpgwapi/inc/class.db_backup.inc.php b/phpgwapi/inc/class.db_backup.inc.php index c33fded96d..b118ea28a3 100644 --- a/phpgwapi/inc/class.db_backup.inc.php +++ b/phpgwapi/inc/class.db_backup.inc.php @@ -105,6 +105,7 @@ class db_backup } $this->db = $this->schema_proc->m_odb; + if (!$this->db->Link_ID) $this->db->connect(); $this->adodb = $this->db->Link_ID; if (isset($GLOBALS['egw_setup']) && is_object($GLOBALS['egw_setup'])) // called from setup { diff --git a/phpgwapi/inc/class.schema_proc.inc.php b/phpgwapi/inc/class.schema_proc.inc.php index a176ac52a8..fc426b2590 100644 --- a/phpgwapi/inc/class.schema_proc.inc.php +++ b/phpgwapi/inc/class.schema_proc.inc.php @@ -112,7 +112,7 @@ class schema_proc $this->m_odb->connect(); $this->capabilities =& $this->m_odb->capabilities; - $this->sType = $dbms ? $dmbs : $this->m_odb->Type; + $this->sType = $dbms ? $dbms : $this->m_odb->Type; $this->adodb = &$this->m_odb->Link_ID; $this->dict = NewDataDictionary($this->adodb);