// Get the help
$context = new DerivativeContext( $this->getMain()->getContext() );
- $context->setSkin( SkinFactory::getDefaultInstance()->makeSkin( 'apioutput' ) );
+ $skinFactory = MediaWikiServices::getInstance()->getSkinFactory();
+ $context->setSkin( $skinFactory->makeSkin( 'apioutput' ) );
$context->setLanguage( $this->getMain()->getLanguage() );
$context->setTitle( SpecialPage::getTitleFor( 'ApiHelp' ) );
$out = new OutputPage( $context );
break;
case 'namespace':
- $namespaces = MWNamespace::getValidNamespaces();
+ $namespaces = MediaWikiServices::getInstance()->
+ getNamespaceInfo()->getValidNamespaces();
if ( isset( $settings[ApiBase::PARAM_EXTRA_NAMESPACES] ) &&
is_array( $settings[ApiBase::PARAM_EXTRA_NAMESPACES] )
) {