Merge "Add documentation to clarify difference between save and upload message"
[lhc/web/wiklou.git] / maintenance / populateContentModel.php
index 3f5d6b6..4f9c7ae 100644 (file)
@@ -37,7 +37,7 @@ class PopulateContentModel extends Maintenance {
        }
 
        public function execute() {
-               $dbw = wfGetDB( DB_MASTER );
+               $dbw = $this->getDB( DB_MASTER );
                $ns = $this->getOption( 'ns' );
                if ( !ctype_digit( $ns ) && $ns !== 'all' ) {
                        $this->error( 'Invalid namespace', 1 );
@@ -178,7 +178,7 @@ class PopulateContentModel extends Maintenance {
                                        if ( $dbFormat === $defaultFormat ) {
                                                $toSave[$defaultModel][] = $row->{$key};
                                        } else { // non-default format, just update now
-                                               $this->output( "Updating model to match format for $table $id of $title... ");
+                                               $this->output( "Updating model to match format for $table $id of $title... " );
                                                $dbw->update(
                                                        $table,
                                                        array( $model_column => $defaultModel ),