1
0
mirror of synced 2025-02-01 04:51:45 +03:00

fixed lazy-connecting for transaction methods

This commit is contained in:
zYne 2007-01-11 22:38:35 +00:00
parent 86ec08c331
commit 56ff937833

View File

@ -422,6 +422,8 @@ class Doctrine_Db implements Countable, IteratorAggregate, Doctrine_Adapter_Inte
*/
public function beginTransaction()
{
$this->connect();
$event = new Doctrine_Db_Event($this, Doctrine_Db_Event::BEGIN);
$this->listener->onPreBeginTransaction($event);
@ -439,6 +441,8 @@ class Doctrine_Db implements Countable, IteratorAggregate, Doctrine_Adapter_Inte
*/
public function commit()
{
$this->connect();
$event = new Doctrine_Db_Event($this, Doctrine_Db_Event::COMMIT);
$this->listener->onPreCommit($event);