Merge "Unit test for User::getEditCount"
[lhc/web/wiklou.git] / maintenance / update.php
index 877f136..e3c993b 100644 (file)
@@ -126,12 +126,18 @@ class UpdateMediaWiki extends Maintenance {
                $updater->doUpdates( $updates );
 
                foreach( $updater->getPostDatabaseUpdateMaintenance() as $maint ) {
-                       if ( $updater->updateRowExists( $maint ) ) {
+                       $child = $this->runChild( $maint );
+
+                       // LoggedUpdateMaintenance is checking the updatelog itself
+                       $isLoggedUpdate = ( $child instanceof LoggedUpdateMaintenance );
+
+                       if ( !$isLoggedUpdate && $updater->updateRowExists( $maint ) ) {
                                continue;
                        }
-                       $child = $this->runChild( $maint );
                        $child->execute();
-                       $updater->insertUpdateRow( $maint );
+                       if ( !$isLoggedUpdate ) {
+                               $updater->insertUpdateRow( $maint );
+                       }
                }
 
                $this->output( "\nDone.\n" );