r66237 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r66236‎ | r66237 | r66238 >
Date:23:21, 11 May 2010
Author:siebrand
Status:ok
Tags:
Comment:
Follow-up r66234: support GENDER in 'siteuser'
Modified paths:
  • /trunk/extensions/Rdf/Rdf.php (modified) (history)
  • /trunk/extensions/RdfRedland/Rdf.php (modified) (history)
  • /trunk/extensions/RdfRedland/test/MwRdfTest_Framework.php (modified) (history)
  • /trunk/phase3/includes/Metadata.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Metadata.php
@@ -122,7 +122,8 @@
123123 } else if( $real = $user->getRealName() ) {
124124 $this->element( $name, $real );
125125 } else {
126 - $this->pageOrString( $name, $user->getUserPage(), wfMsg( 'siteuser', $user->getName() ) );
 126+ $userName = $user->getName();
 127+ $this->pageOrString( $name, $user->getUserPage(), wfMsgExt( 'siteuser', 'parsemag', $userName, $userName ) );
127128 }
128129 }
129130
Index: trunk/extensions/Rdf/Rdf.php
@@ -791,7 +791,7 @@
792792 $user_name = User::whoIs($id);
793793 }
794794 return MwRdfPageOrString($wgContLang->getNsText(NS_USER) . ':' . $user_name,
795 - wfMsg('siteuser', $user_name));
 795+ wfMsgExt( 'siteuser', 'parsemag', $user_name, $user_name ) );
796796 }
797797 }
798798
Index: trunk/extensions/RdfRedland/test/MwRdfTest_Framework.php
@@ -292,14 +292,14 @@
293293 $res = MwRdf::PersonToResource(
294294 $user->getID(), $user->getName(), $user->getRealName() );
295295 $this->assertTrue( $res instanceof LibRDF_LiteralNode );
296 - $this->assertEquals( wfMsg( 'siteuser', "MwRdfPagelessNamelessUser" ), "$res" );
 296+ $this->assertEquals( wfMsgExt( 'siteuser', 'parsemag', "MwRdfPagelessNamelessUser", "MwRdfPagelessNamelessUser" ), "$res" );
297297 }
298298
299299 public function testPersonToResource_JustId_UserHasNeitherRealNameNorPage() {
300300 $user = MwRdfTest::CreateUserWithoutRealNameOrPage();
301301 $res = MwRdf::PersonToResource( $user->getID() );
302302 $this->assertTrue( $res instanceof LibRDF_LiteralNode );
303 - $this->assertEquals( wfMsg( 'siteuser', "MwRdfPagelessNamelessUser" ), "$res" );
 303+ $this->assertEquals( wfMsgExt( 'siteuser', 'parsemag', "MwRdfPagelessNamelessUser", "MwRdfPagelessNamelessUser" ), "$res" );
304304 }
305305
306306 public function testPersonToResource_AnonymousUser() {
Index: trunk/extensions/RdfRedland/Rdf.php
@@ -331,7 +331,9 @@
332332 $mf = self::ModelingAgent( $user->getUserPage() );
333333 return $mf->titleResource();
334334 }
335 - return self::LiteralNode( wfMsg( 'siteuser', $user->getName() ) );
 335+
 336+ $userName = $user->getName();
 337+ return self::LiteralNode( wfMsgExt( 'siteuser', 'parsemag', $userName, $userName ) );
336338 }
337339
338340 public function RightsResource() {

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r66234* support GENDER in 'siteuser'...siebrand22:54, 11 May 2010

Status & tagging log