Revert "Add type hint against LinkTarget"
[lhc/web/wiklou.git] / maintenance / populateFilearchiveSha1.php
index a3099f9..24c25b1 100644 (file)
@@ -32,7 +32,7 @@ require_once __DIR__ . '/Maintenance.php';
 class PopulateFilearchiveSha1 extends LoggedUpdateMaintenance {
        public function __construct() {
                parent::__construct();
-               $this->mDescription = "Populate the fa_sha1 field from fa_storage_key";
+               $this->addDescription( 'Populate the fa_sha1 field from fa_storage_key' );
        }
 
        protected function getUpdateKey() {
@@ -45,7 +45,7 @@ class PopulateFilearchiveSha1 extends LoggedUpdateMaintenance {
 
        public function doDBUpdates() {
                $startTime = microtime( true );
-               $dbw = wfGetDB( DB_MASTER );
+               $dbw = $this->getDB( DB_MASTER );
                $table = 'filearchive';
                $conds = array( 'fa_sha1' => '', 'fa_storage_key IS NOT NULL' );