Refactor the database manager.

This commit is contained in:
Taylor Otwell 2011-08-08 10:51:46 -05:00
parent a1956f016c
commit 73065d12c2
1 changed files with 4 additions and 1 deletions

View File

@ -22,7 +22,10 @@ class Manager {
*/
public static function connection($connection = null)
{
if (is_null($connection)) $connection = Config::get('db.default');
if (is_null($connection))
{
$connection = Config::get('db.default');
}
if ( ! array_key_exists($connection, static::$connections))
{