Index: trunk/phase3/includes/Wiki.php |
— | — | @@ -328,12 +328,16 @@ |
329 | 329 | */ |
330 | 330 | function finalCleanup ( &$deferredUpdates, &$output ) { |
331 | 331 | wfProfileIn( __METHOD__ ); |
| 332 | + # Now commit any transactions, so that unreported errors after output() don't roll back the whole thing |
| 333 | + $factory = wfGetLBFactory(); |
| 334 | + $factory->commitMasterChanges(); |
| 335 | + # Output everything! |
| 336 | + $output->output(); |
| 337 | + # Do any deferred jobs |
332 | 338 | $this->doUpdates( $deferredUpdates ); |
333 | 339 | $this->doJobs(); |
334 | | - # Now commit any transactions, so that unreported errors after output() don't roll back the whole thing |
335 | | - $factory = wfGetLBFactory(); |
| 340 | + # Commit and close up! |
336 | 341 | $factory->shutdown(); |
337 | | - $output->output(); |
338 | 342 | wfProfileOut( __METHOD__ ); |
339 | 343 | } |
340 | 344 | |