# Namespace which no longer exists. Put the page in the main namespace
# since we don't have any idea of the old namespace name. See T70501.
- if ( !MWNamespace::exists( $ns ) ) {
+ if ( !MediaWikiServices::getInstance()->getNamespaceInfo()->exists( $ns ) ) {
$ns = 0;
}