(bug 9691) Add type parameter to ModifyUITemplate function calls
authorChad Horohoe <demon@users.mediawiki.org>
Mon, 27 Jul 2009 23:53:23 +0000 (23:53 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Mon, 27 Jul 2009 23:53:23 +0000 (23:53 +0000)
RELEASE-NOTES
includes/AuthPlugin.php
includes/specials/SpecialUserlogin.php

index 837157f..c0c5c14 100644 (file)
@@ -163,6 +163,7 @@ this. Was used when mwEmbed was going to be an extension.
 * (bug 471) Allow RSS feeds for watchlist, using an opt-in security token
 * (bug 10812) Interwiki links can have names and descriptions, fetched from 
   message 'interwiki-desc-PREFIX', not really used anywhere yet though
+* (bug 9691) Add type (signup or login) parameter to AuthPlugin::ModifyUITemplate()
 
 === Bug fixes in 1.16 ===
 
index 5ac790c..eacabd4 100644 (file)
@@ -63,8 +63,9 @@ class AuthPlugin {
         * Modify options in the login template.
         *
         * @param $template UserLoginTemplate object.
+        * @param $type String 'signup' or 'login'.
         */
-       public function modifyUITemplate( &$template ) {
+       public function modifyUITemplate( &$template, &$type ) {
                # Override this!
                $template->set( 'usedomain', false );
        }
index 2aa6977..da06df0 100644 (file)
@@ -931,7 +931,7 @@ class LoginForm {
                }
 
                // Give authentication and captcha plugins a chance to modify the form
-               $wgAuth->modifyUITemplate( $template );
+               $wgAuth->modifyUITemplate( $template, $this->mType );
                if ( $this->mType == 'signup' ) {
                        wfRunHooks( 'UserCreateForm', array( &$template ) );
                } else {