Revert "Add type hint against LinkTarget"
[lhc/web/wiklou.git] / maintenance / resetUserTokens.php
index 08be553..7acf975 100644 (file)
@@ -34,8 +34,9 @@ require_once __DIR__ . '/Maintenance.php';
 class ResetUserTokens extends Maintenance {
        public function __construct() {
                parent::__construct();
-               $this->mDescription =
-                       "Reset the user_token of all users on the wiki. Note that this may log some of them out.";
+               $this->addDescription(
+                       'Reset the user_token of all users on the wiki. Note that this may log some of them out.'
+               );
                $this->addOption( 'nowarn', "Hides the 5 seconds warning", false, false );
                $this->addOption(
                        'nulls',
@@ -65,7 +66,7 @@ class ResetUserTokens extends Maintenance {
                }
 
                // We list user by user_id from one of the slave database
-               $dbr = wfGetDB( DB_SLAVE );
+               $dbr = $this->getDB( DB_SLAVE );
 
                $where = array();
                if ( $this->nullsOnly ) {