From 34f68cab0ddc437e623ffdacbb6a46cbd4e55aca Mon Sep 17 00:00:00 2001 From: Darko Date: Mon, 15 Sep 2014 11:57:40 +0200 Subject: [PATCH] Small reversal of changes to Settings and db. --- lib/copy_this/www/lib/framework/Settings.php | 3 +-- lib/copy_this/www/lib/framework/db.php | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/copy_this/www/lib/framework/Settings.php b/lib/copy_this/www/lib/framework/Settings.php index aebcf1108..8b7da967a 100644 --- a/lib/copy_this/www/lib/framework/Settings.php +++ b/lib/copy_this/www/lib/framework/Settings.php @@ -46,9 +46,8 @@ class Settings extends DB public function __construct(array $options = []) { parent::__construct($options); - $result = parent::exec("describe settings"); + $result = parent::exec("describe settings", true); $this->table = ($result === false) ? 'settings' : 'site'; - return $this->pdo; } diff --git a/lib/copy_this/www/lib/framework/db.php b/lib/copy_this/www/lib/framework/db.php index fc26640e5..39844257d 100644 --- a/lib/copy_this/www/lib/framework/db.php +++ b/lib/copy_this/www/lib/framework/db.php @@ -516,7 +516,7 @@ class DB extends \PDO } } - /*/** + /** * Direct query. Return the affected row count. http://www.php.net/manual/en/pdo.exec.php * * @note If not "consumed", causes this error: @@ -529,7 +529,7 @@ class DB extends \PDO * * @return bool|int|PDOStatement */ - /*public function exec($query, $silent = false) + public function exec($query, $silent = false) { if (empty($query)) { return false; @@ -568,7 +568,7 @@ class DB extends \PDO return false; } - }*/ + } /** * Returns an array of result (empty array if no results or an error occurs)