ApiParse: Add Skin::getDefaultModules() in useskin mode

Bug: T130632
Change-Id: Idc41934eb89ec8f928bbea3b2135c3f246fe3925
This commit is contained in:
Timo Tijhof 2017-04-20 17:25:21 -07:00
parent 0048c3e255
commit 90c95fc7f2

View file

@ -312,6 +312,13 @@ class ApiParse extends ApiBase {
$outputPage = new OutputPage( $context ); $outputPage = new OutputPage( $context );
$outputPage->addParserOutputMetadata( $p_result ); $outputPage->addParserOutputMetadata( $p_result );
$context->setOutput( $outputPage ); $context->setOutput( $outputPage );
if ( $skin ) {
// Based on OutputPage::output()
foreach ( $skin->getDefaultModules() as $group ) {
$outputPage->addModules( $group );
}
}
} }
if ( !is_null( $oldid ) ) { if ( !is_null( $oldid ) ) {