diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2011-06-22 11:28:20 +0200 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2011-06-22 11:28:20 +0200 |
commit | 9db190c7e736ec8d063187d4241b59feaf7dc2d1 (patch) | |
tree | 46d1a0dee7febef5c2d57a9f7b972be16a163b3d /includes/filerepo/ForeignDBRepo.php | |
parent | 78677c7bbdcc9739f6c10c75935898a20e1acd9e (diff) |
update to MediaWiki 1.17.0
Diffstat (limited to 'includes/filerepo/ForeignDBRepo.php')
-rw-r--r-- | includes/filerepo/ForeignDBRepo.php | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/includes/filerepo/ForeignDBRepo.php b/includes/filerepo/ForeignDBRepo.php index 35c2c4bf..590350b4 100644 --- a/includes/filerepo/ForeignDBRepo.php +++ b/includes/filerepo/ForeignDBRepo.php @@ -1,7 +1,14 @@ <?php +/** + * A foreign repository with an accessible MediaWiki database + * + * @file + * @ingroup FileRepo + */ /** * A foreign repository with an accessible MediaWiki database + * * @ingroup FileRepo */ class ForeignDBRepo extends LocalRepo { @@ -28,10 +35,16 @@ class ForeignDBRepo extends LocalRepo { function getMasterDB() { if ( !isset( $this->dbConn ) ) { - $class = 'Database' . ucfirst( $this->dbType ); - $this->dbConn = new $class( $this->dbServer, $this->dbUser, - $this->dbPassword, $this->dbName, false, $this->dbFlags, - $this->tablePrefix ); + $this->dbConn = DatabaseBase::newFromType( $this->dbType, + array( + 'server' => $this->dbServer, + 'user' => $this->dbUser, + 'password' => $this->dbPassword, + 'dbname' => $this->dbName, + 'flags' => $this->dbFlags, + 'tableprefix' => $this->tablePrefix + ) + ); } return $this->dbConn; } @@ -65,7 +78,7 @@ class ForeignDBRepo extends LocalRepo { function publish( $srcPath, $dstRel, $archiveRel, $flags = 0 ) { throw new MWException( get_class($this) . ': write operations are not supported' ); } - function deleteBatch( $fileMap ) { + function deleteBatch( $sourceDestPairs ) { throw new MWException( get_class($this) . ': write operations are not supported' ); } } |