diff --git a/classes/Session.class.php b/classes/Session.class.php index 4d8e47f0a..b63dfe01a 100644 --- a/classes/Session.class.php +++ b/classes/Session.class.php @@ -414,6 +414,8 @@ abstract class Doctrine_Session extends Doctrine_Configurable implements Countab public function bulkInsert() { if(empty($this->insert)) return false; + + foreach($this->insert as $name => $inserts) { if( ! isset($inserts[0])) diff --git a/classes/Session/Mysql.class.php b/classes/Session/Mysql.class.php index a2e27d910..e26789976 100644 --- a/classes/Session/Mysql.class.php +++ b/classes/Session/Mysql.class.php @@ -75,8 +75,6 @@ class Doctrine_Session_Mysql extends Doctrine_Session_Common { if(empty($this->insert)) return false; - $values = $this->getMaximumValues(array_keys($this->insert)); - foreach($this->insert as $name => $inserts) { if( ! isset($inserts[0])) continue; @@ -156,6 +154,7 @@ class Doctrine_Session_Mysql extends Doctrine_Session_Common { } } } + $this->insert = array(); return true; }