Refactor profiling output from profiling
[lhc/web/wiklou.git] / maintenance / Maintenance.php
index d740f56..3f8f6e8 100644 (file)
@@ -446,7 +446,6 @@ abstract class Maintenance {
                $this->addOption( 'server', "The protocol and server name to use in URLs, e.g. " .
                        "http://en.wikipedia.org. This is sometimes necessary because " .
                        "server name detection may fail in command line scripts.", false, true );
-               $this->addOption( 'profiler', 'Set to "text" or "trace" to show profiling output', false, true );
 
                # Save generic options to display them separately in help
                $this->mGenericParameters = $this->mParams;
@@ -930,16 +929,6 @@ abstract class Maintenance {
                // @codingStandardsIgnoreStart
 
                $this->adjustMemoryLimit();
-
-               // Per-script profiling; useful for debugging
-               $forcedProfiler = $this->getOption( 'profiler' );
-               if ( $forcedProfiler === 'text' ) {
-                       Profiler::setInstance( new ProfilerSimpleText( array() ) );
-                       Profiler::instance()->setTemplated( true );
-               } elseif ( $forcedProfiler === 'trace' ) {
-                       Profiler::setInstance( new ProfilerSimpleTrace( array() ) );
-                       Profiler::instance()->setTemplated( true );
-               }
        }
 
        /**