From: Aaron Schulz Date: Wed, 17 Apr 2013 01:20:00 +0000 (-0700) Subject: Set up the profiler in CLI mode. X-Git-Tag: 1.31.0-rc.0~19977^2 X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=820de0f13b8921a64bec435024dc0778b0eb1251;p=lhc%2Fweb%2Fwiklou.git Set up the profiler in CLI mode. Change-Id: I7f36786573870b66b4f1e93c2fc2e444f1ae1252 --- diff --git a/maintenance/doMaintenance.php b/maintenance/doMaintenance.php index 15b00167d2..210c5a2663 100644 --- a/maintenance/doMaintenance.php +++ b/maintenance/doMaintenance.php @@ -60,10 +60,15 @@ if ( isset( $_SERVER['MW_COMPILED'] ) ) { # Get the MWInit class require_once( "$IP/includes/Init.php" ); require_once( "$IP/includes/AutoLoader.php" ); + # Stub the profiler + require_once( "$IP/includes/profiler/Profiler.php" ); } -# Stub the profiler -require_once( MWInit::compiledPath( 'includes/profiler/Profiler.php' ) ); +# Start the profiler +$wgProfiler = array(); +if ( file_exists( "$IP/StartProfiler.php" ) ) { + require( "$IP/StartProfiler.php" ); +} // Some other requires if ( !defined( 'MW_COMPILED' ) ) {