Make name box enabled/disabled based on right to use it, not on whether we're changin...
authorChad Horohoe <demon@users.mediawiki.org>
Fri, 20 Feb 2009 18:57:13 +0000 (18:57 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Fri, 20 Feb 2009 18:57:13 +0000 (18:57 +0000)
includes/specials/SpecialResetpass.php

index 60453bb..49e2530 100644 (file)
@@ -125,7 +125,7 @@ class SpecialResetpass extends SpecialPage {
                        wfMsgExt( 'resetpass_text', array( 'parse' ) ) .
                        Xml::openElement( 'table', array( 'id' => 'mw-resetpass-table' ) ) .
                        $this->pretty( array(
-                               array( 'wpName', 'username', 'text', $this->mUserName, !$this->mSelfChange ),
+                               array( 'wpName', 'username', 'text', $this->mUserName, $wgUser->isAllowed( 'reset-passwords' ) ),
                                array( 'wpPassword', $oldpassMsg, 'password', $this->mOldpass, $this->mSelfChange ),
                                array( 'wpNewPassword', 'newpassword', 'password', '', true ),
                                array( 'wpRetype', 'retypenew', 'password', '', true ),