Use hasSubjectNamespace in Skin.php instead of namespace tests.
Change-Id: I11c5657de868a99429d400e0edb05707ec6069fb
This commit is contained in:
parent
55a52d5915
commit
09ada02d6e
1 changed files with 2 additions and 2 deletions
|
|
@ -290,8 +290,8 @@ abstract class Skin extends ContextSource {
|
|||
return $this->mRelevantUser;
|
||||
}
|
||||
$title = $this->getRelevantTitle();
|
||||
if( $title->getNamespace() == NS_USER || $title->getNamespace() == NS_USER_TALK ) {
|
||||
$rootUser = strtok( $title->getText(), '/' );
|
||||
if( $title->hasSubjectNamespace( NS_USER ) ) {
|
||||
$rootUser = $title->getRootText();
|
||||
if ( User::isIP( $rootUser ) ) {
|
||||
$this->mRelevantUser = User::newFromName( $rootUser, false );
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue