X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FdumpUploads.php;h=8d63fe55f90784bcc9642adec3555de95d6c3c9a;hb=f5b9af121a07ecc674a63cbc65c3a01e9fa7d785;hp=ec276c1a69ec3445f8dd8f2be385e7f3668eec21;hpb=fb7b3eebeb8de47eb42e8d6ccf204106a2d6d9e4;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/dumpUploads.php b/maintenance/dumpUploads.php index ec276c1a69..8d63fe55f9 100644 --- a/maintenance/dumpUploads.php +++ b/maintenance/dumpUploads.php @@ -76,7 +76,7 @@ By default, outputs relative paths against the parent directory of $wgUploadDire * @param bool $shared True to pass shared-dir settings to hash func */ function fetchUsed( $shared ) { - $dbr = $this->getDB( DB_SLAVE ); + $dbr = $this->getDB( DB_REPLICA ); $image = $dbr->tableName( 'image' ); $imagelinks = $dbr->tableName( 'imagelinks' ); @@ -97,7 +97,7 @@ By default, outputs relative paths against the parent directory of $wgUploadDire * @param bool $shared True to pass shared-dir settings to hash func */ function fetchLocal( $shared ) { - $dbr = $this->getDB( DB_SLAVE ); + $dbr = $this->getDB( DB_REPLICA ); $result = $dbr->select( 'image', [ 'img_name' ], '', @@ -111,7 +111,7 @@ By default, outputs relative paths against the parent directory of $wgUploadDire function outputItem( $name, $shared ) { $file = wfFindFile( $name ); if ( $file && $this->filterItem( $file, $shared ) ) { - $filename = $file->getPath(); + $filename = $file->getLocalRefPath(); $rel = wfRelativePath( $filename, $this->mBasePath ); $this->output( "$rel\n" ); } else {