Cleanup for r63578: Use Maintenance::error(), that's what its for
authorChad Horohoe <demon@users.mediawiki.org>
Tue, 14 Dec 2010 13:37:53 +0000 (13:37 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Tue, 14 Dec 2010 13:37:53 +0000 (13:37 +0000)
maintenance/updateDoubleWidthSearch.php
maintenance/updateSearchIndex.php

index 7899628..b187880 100644 (file)
@@ -43,8 +43,7 @@ class UpdateDoubleWidthSearch extends Maintenance {
 
                $dbw = wfGetDB( DB_MASTER );
                if ( $dbw->getType() !== 'mysql' ) {
-                       $this->output( "This change is only needed on MySQL, quitting.\n" );
-                       exit( 1 );
+                       $this->error( "This change is only needed on MySQL, quitting.\n", true );
                }
 
                $res = $this->findRows( $dbw );
index eede109..6de3ced 100644 (file)
@@ -70,10 +70,10 @@ class UpdateSearchIndex extends Maintenance {
                                fwrite( $file, $end );
                                fclose( $file );
                        } else {
-                               $this->output( "*** Couldn't write to the $posFile!\n" );
+                               $this->error( "*** Couldn't write to the $posFile!\n" );
                        }
                } else {
-                       $this->output( "*** Couldn't write to the $posFile!\n" );
+                       $this->error( "*** Couldn't write to the $posFile!\n" );
                }
        }