From: Jens Frank Date: Sun, 13 Mar 2005 17:49:28 +0000 (+0000) Subject: Bug 1617: Incorrect login message when using AuthPlugin X-Git-Tag: 1.5.0alpha1~622 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/password.php?a=commitdiff_plain;h=c119f4e39c3643f9ebfdabfb88fec5a701c7db2d;p=lhc%2Fweb%2Fwiklou.git Bug 1617: Incorrect login message when using AuthPlugin --- diff --git a/includes/SpecialUserlogin.php b/includes/SpecialUserlogin.php index 76db17bb81..1f9c1bcd03 100644 --- a/includes/SpecialUserlogin.php +++ b/includes/SpecialUserlogin.php @@ -295,10 +295,13 @@ class LoginForm { * automatically create a new account for users that * are externally defined but have not yet logged in. */ - if( $wgAuth->autoCreate() && - $wgAuth->userExists( $u->getName() ) && - $wgAuth->authenticate( $u->getName(), $this->mPassword ) ) { - $u =& $this->initUser( $u ); + if ( $wgAuth->autoCreate() && $wgAuth->userExists( $u->getName() ) ) { + if ( $wgAuth->authenticate( $u->getName(), $this->mPassword ) ) { + $u =& $this->initUser( $u ); + } else { + $this->mainLoginForm( wfMsg( 'wrongpassword' ) ); + return; + } } else { $this->mainLoginForm( wfMsg( 'nosuchuser', $u->getName() ) ); return;