Merge "New hook for filters on Special:Contributions form"
[lhc/web/wiklou.git] / maintenance / fetchText.php
index dd4f760..989e90a 100644 (file)
@@ -32,8 +32,10 @@ require_once __DIR__ . '/Maintenance.php';
 class FetchText extends Maintenance {
        public function __construct() {
                parent::__construct();
-               $this->mDescription = "Fetch the raw revision blob from an old_id.";
-               $this->mDescription .= "\nNOTE: Export transformations are NOT applied. This is left to backupTextPass.php";
+               $this->addDescription( "Fetch the raw revision blob from an old_id.\n" .
+                       "NOTE: Export transformations are NOT applied. " .
+                       "This is left to backupTextPass.php"
+               );
        }
 
        /**
@@ -47,7 +49,7 @@ class FetchText extends Maintenance {
         * note that the text string itself is *not* followed by newline
         */
        public function execute() {
-               $db = wfGetDB( DB_SLAVE );
+               $db = $this->getDB( DB_SLAVE );
                $stdin = $this->getStdin();
                while ( !feof( $stdin ) ) {
                        $line = fgets( $stdin );