X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=includes%2Fspecials%2FSpecialListDuplicatedFiles.php;h=52c710dd3373ac91b72f69ea01aafa7bf1f8e28d;hb=d46d8bb58d4edfc4a4ed144d39c9a054516a5514;hp=49fa417c0e3b10eb83ec457361be6731aa405f9b;hpb=8eac2feedb7ee093d2c48504e1eb2b8a9dbc8452;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/specials/SpecialListDuplicatedFiles.php b/includes/specials/SpecialListDuplicatedFiles.php index 49fa417c0e..52c710dd33 100644 --- a/includes/specials/SpecialListDuplicatedFiles.php +++ b/includes/specials/SpecialListDuplicatedFiles.php @@ -24,6 +24,8 @@ * @author Brian Wolff */ +use Wikimedia\Rdbms\ResultWrapper; + /** * Special:ListDuplicatedFiles Lists all files where the current version is * a duplicate of the current version of some other file. @@ -75,16 +77,7 @@ class ListDuplicatedFilesPage extends QueryPage { * @param ResultWrapper $res */ function preprocessResults( $db, $res ) { - if ( $res->numRows() > 0 ) { - $linkBatch = new LinkBatch(); - - foreach ( $res as $row ) { - $linkBatch->add( $row->namespace, $row->title ); - } - - $res->seek( 0 ); - $linkBatch->execute(); - } + $this->executeLBFromResultWrapper( $res ); } /**