From 5321ce98ec640c33e615b4c3b45f4d2189e77a3a Mon Sep 17 00:00:00 2001 From: the_undefined Date: Tue, 22 Apr 2008 16:59:26 +0000 Subject: [PATCH] Giving bool return value to DboSource::insertMulti git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6708 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/libs/model/datasources/dbo_source.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cake/libs/model/datasources/dbo_source.php b/cake/libs/model/datasources/dbo_source.php index e5cfb1897..468040175 100644 --- a/cake/libs/model/datasources/dbo_source.php +++ b/cake/libs/model/datasources/dbo_source.php @@ -1968,6 +1968,7 @@ class DboSource extends DataSource { * @param string $table * @param string $fields * @param array $values + * @return bool True on success, false on failure */ function insertMulti($table, $fields, $values) { $table = $this->fullTableName($table); @@ -1975,7 +1976,7 @@ class DboSource extends DataSource { $fields = join(', ', array_map(array(&$this, 'name'), $fields)); } $values = implode(', ', $values); - $this->query("INSERT INTO {$table} ({$fields}) VALUES {$values}"); + return $this->execute("INSERT INTO {$table} ({$fields}) VALUES {$values}"); } /** * Inserts multiple values into a join table