http://www.mediawiki.org/wiki/Special:Code/MediaWiki/66258

Revision: 66258
Author:   bawolff
Date:     2010-05-12 06:31:40 +0000 (Wed, 12 May 2010)

Log Message:
-----------
Special:Userrights didn't recognize user as self if person didn't capitalize
the first letter of their name, and thus wouldn't honour $wgGroupsAddToSelf
if user accidently forgot to capitalize their name.

Possibly a regression from r57064

Modified Paths:
--------------
    trunk/phase3/RELEASE-NOTES
    trunk/phase3/includes/specials/SpecialUserrights.php

Modified: trunk/phase3/RELEASE-NOTES
===================================================================
--- trunk/phase3/RELEASE-NOTES  2010-05-12 04:45:06 UTC (rev 66257)
+++ trunk/phase3/RELEASE-NOTES  2010-05-12 06:31:40 UTC (rev 66258)
@@ -162,6 +162,7 @@
   MediaWiki:Subject-preview when previewing summary
 * (bug 23426) The {{REVISIONMONTH}} variable is now zero-padded and added new
   variable {{REVISIONMONTH1}} when unpadded version is needed.
+* Special:Userrights didn't recognize user as changing his/her own rights if 
user did not capitalize first letter of username.
 
 === API changes in 1.17 ===
 * (bug 22738) Allow filtering by action type on query=logevent

Modified: trunk/phase3/includes/specials/SpecialUserrights.php
===================================================================
--- trunk/phase3/includes/specials/SpecialUserrights.php        2010-05-12 
04:45:06 UTC (rev 66257)
+++ trunk/phase3/includes/specials/SpecialUserrights.php        2010-05-12 
06:31:40 UTC (rev 66258)
@@ -77,7 +77,7 @@
                                $this->mTarget = $wgUser->getName();
                }
 
-               if ( $this->mTarget == $wgUser->getName() )
+               if ( User::getCanonicalName( $this->mTarget ) == 
$wgUser->getName() )
                        $this->isself = true;
 
                if( !$this->userCanChangeRights( $wgUser, true ) ) {



_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to