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

Revision: 97986
Author:   aaron
Date:     2011-09-24 07:25:22 +0000 (Sat, 24 Sep 2011)
Log Message:
-----------
Fixed fatal due to boolean passed in as $user to checkIfAccountNameIsPending()

Modified Paths:
--------------
    trunk/extensions/ConfirmAccount/presentation/ConfirmAccountUI.hooks.php
    
trunk/extensions/ConfirmAccount/presentation/specialpages/actions/RequestAccount_body.php

Modified: 
trunk/extensions/ConfirmAccount/presentation/ConfirmAccountUI.hooks.php
===================================================================
--- trunk/extensions/ConfirmAccount/presentation/ConfirmAccountUI.hooks.php     
2011-09-24 07:10:01 UTC (rev 97985)
+++ trunk/extensions/ConfirmAccount/presentation/ConfirmAccountUI.hooks.php     
2011-09-24 07:25:22 UTC (rev 97986)
@@ -22,7 +22,7 @@
                return true;
        }
 
-       public static function checkIfAccountNameIsPending( $user, &$abortError 
) {
+       public static function checkIfAccountNameIsPending( User $user, 
&$abortError ) {
                # If an account is made with name X, and one is pending with 
name X
                # we will have problems if the pending one is later confirmed
                $dbw = wfGetDB( DB_MASTER );

Modified: 
trunk/extensions/ConfirmAccount/presentation/specialpages/actions/RequestAccount_body.php
===================================================================
--- 
trunk/extensions/ConfirmAccount/presentation/specialpages/actions/RequestAccount_body.php
   2011-09-24 07:10:01 UTC (rev 97985)
+++ 
trunk/extensions/ConfirmAccount/presentation/specialpages/actions/RequestAccount_body.php
   2011-09-24 07:25:22 UTC (rev 97986)
@@ -225,7 +225,7 @@
                # Now create a dummy user ($u) and check if it is valid
                $name = trim( $this->mUsername );
                $u = User::newFromName( $name, 'creatable' );
-               if ( is_null( $u ) ) {
+               if ( !$u ) {
                        $this->showForm( wfMsgHtml( 'noname' ) );
                        return;
                }


_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to