From 6a01f3a52b349dd4ec5bc2cf934ed959d7d78913 Mon Sep 17 00:00:00 2001 From: Krivchikov Dmitry Date: Wed, 25 Nov 2015 23:13:47 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D1=80=D0=B0=D0=B1=D0=BE=D1=82?= =?UTF-8?q?=D0=B0=D0=BD=D0=B0=20=D0=B1=D0=B0=D0=B7=D0=BE=D0=B2=D0=B0=D1=8F?= =?UTF-8?q?=20=D0=BC=D0=BE=D0=B4=D0=B5=D0=BB=D1=8C=20-=20=D0=BF=D1=80?= =?UTF-8?q?=D0=B8=20=D1=81=D0=BE=D1=85=D1=80=D0=B0=D0=BD=D0=B5=D0=BD=D0=B8?= =?UTF-8?q?=D0=B8=20=D0=B8=D0=BC=D0=B5=D0=BD=D0=B0=20=D1=81=D1=82=D0=BE?= =?UTF-8?q?=D0=BB=D0=B1=D1=86=D0=BE=D0=B2=20=D0=B1=D0=B5=D1=80=D1=83=D1=82?= =?UTF-8?q?=D1=81=D1=8F=20=D0=B2=20=D0=BA=D0=B0=D0=B2=D1=8B=D1=87=D0=BA?= =?UTF-8?q?=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ground/classes/Model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ground/classes/Model.php b/ground/classes/Model.php index 85f9d1b..2e29508 100644 --- a/ground/classes/Model.php +++ b/ground/classes/Model.php @@ -284,7 +284,7 @@ abstract class Model $values = $this->_vals_; unset($values[$this->_primaryKey_]); - $request = App::DB()->prepare('UPDATE ' . $this->_tableName_ . ' SET ' . implode('=?, ', array_keys($values)) . '=? WHERE ' . $this->_primaryKey_ . '=' . $this->_id_); + $request = App::DB()->prepare('UPDATE ' . $this->_tableName_ . ' SET `' . implode('`=?, `', array_keys($values)) . '`=? WHERE ' . $this->_primaryKey_ . '=' . $this->_id_); $res = $request->execute(array_values($values)); return $res ? $this : FALSE;