Created
December 11, 2015 21:25
-
-
Save yunake/c872d0baeda37035c414 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
$master_success = @mysqli_select_db($this->read_link, $database) or $this->error("[READ] Unable to select database", $this->read_link); | |
if($this->write_link) | |
{ | |
$slave_success = @mysqli_select_db($this->write_link, $database) or $this->error("[WRITE] Unable to select slave database", $this->write_link); | |
$success = ($master_success && $slave_success ? true : false); | |
} | |
else | |
{ | |
$success = $master_success; | |
} | |
return $success; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment