Created
August 31, 2012 01:55
-
-
Save jonathaningram/3547720 to your computer and use it in GitHub Desktop.
Doctrine MasterSlaveConnection beginTransaction connects to master and then calls parent method which overwrites connection
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class MasterSlaveConnection | |
{ | |
public function beginTransaction() | |
{ | |
$this->connect('master'); | |
return parent::beginTransaction(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment