X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2Frebuildtextindex.php;h=37636c85a8ab6d50efe712aa0879bdc0ea52f714;hb=768b2de54f5c51c7b518891421db6708721fa525;hp=e8d59bc4bcdc8650cee01cad2baf761dc466cfd2;hpb=04fdc78370dbc042116488d6826e19bf3910273b;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/rebuildtextindex.php b/maintenance/rebuildtextindex.php index e8d59bc4bc..37636c85a8 100644 --- a/maintenance/rebuildtextindex.php +++ b/maintenance/rebuildtextindex.php @@ -36,13 +36,13 @@ class RebuildTextIndex extends Maintenance { const RTI_CHUNK_SIZE = 500; /** - * @var DatabaseBase + * @var Database */ private $db; public function __construct() { parent::__construct(); - $this->mDescription = "Rebuild search index table from scratch"; + $this->addDescription( 'Rebuild search index table from scratch' ); } public function getDbType() { @@ -102,8 +102,8 @@ class RebuildTextIndex extends Maintenance { } $end = $n + self::RTI_CHUNK_SIZE - 1; - $res = $this->db->select( array( 'page', 'revision', 'text' ), $fields, - array( "page_id BETWEEN $n AND $end", 'page_latest = rev_id', 'rev_text_id = old_id' ), + $res = $this->db->select( [ 'page', 'revision', 'text' ], $fields, + [ "page_id BETWEEN $n AND $end", 'page_latest = rev_id', 'rev_text_id = old_id' ], __METHOD__ );