Use ParserOptions::newFromContext() instead of 'new ParserOptions' to use the local...
authorAlexandre Emsenhuber <ialex@users.mediawiki.org>
Sat, 19 Nov 2011 08:54:03 +0000 (08:54 +0000)
committerAlexandre Emsenhuber <ialex@users.mediawiki.org>
Sat, 19 Nov 2011 08:54:03 +0000 (08:54 +0000)
includes/api/ApiExpandTemplates.php

index 7fbbb56..cf2bc46 100644 (file)
@@ -54,7 +54,7 @@ class ApiExpandTemplates extends ApiBase {
 
                // Parse text
                global $wgParser;
-               $options = new ParserOptions();
+               $options = ParserOptions::newFromContext( $this->getContext() );
 
                if ( $params['includecomments'] ) {
                        $options->setRemoveComments( false );