doUpdate(); if ( $doCommit && $dbw->trxLevel() ) { $dbw->commit( __METHOD__, 'flush' ); } } catch ( Exception $e ) { // We don't want exceptions thrown during deferred updates to // be reported to the user since the output is already sent. // Instead we just log them. if ( !$e instanceof ErrorPageError ) { MWExceptionHandler::logException( $e ); } } } $updates = array_merge( $wgDeferredUpdateList, self::$updates ); } } /** * Clear all pending updates without performing them. Generally, you don't * want or need to call this. Unit tests need it though. */ public static function clearPendingUpdates() { global $wgDeferredUpdateList; $wgDeferredUpdateList = self::$updates = array(); } }