r67285 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r67284‎ | r67285 | r67286 >
Date:17:31, 3 June 2010
Author:simetrical
Status:ok
Tags:
Comment:
Password not always required on account creation

Bug 23769. It's not required when the account is being created by
e-mail, regardless of $wgMinimalPasswordLength. This commit technically
does nothing, given r67283, but it will keep the bug fixed even in the
future when r67283 can be reverted.
Modified paths:
  • /trunk/phase3/includes/User.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/User.php
@@ -3714,6 +3714,10 @@
37153715 *
37163716 * Obviously, you still need to do server-side checking.
37173717 *
 3718+ * NOTE: A combination of bugs in various browsers means that this function
 3719+ * actually just returns array() unconditionally at the moment. May as
 3720+ * well keep it around for when the browser bugs get fixed, though.
 3721+ *
37183722 * @return array Array of HTML attributes suitable for feeding to
37193723 * Html::element(), directly or indirectly. (Don't feed to Xml::*()!
37203724 * That will potentially output invalid XHTML 1.0 Transitional, and will
@@ -3728,7 +3732,14 @@
37293733
37303734 # Note that the pattern requirement will always be satisfied if the
37313735 # input is empty, so we need required in all cases.
3732 - $ret = array( 'required' );
 3736+ #
 3737+ # FIXME (bug 23769): This needs to not claim the password is required
 3738+ # if e-mail confirmation is being used. Since HTML5 input validation
 3739+ # is b0rked anyway in some browsers, just return nothing. When it's
 3740+ # re-enabled, fix this code to not output required for e-mail
 3741+ # registration.
 3742+ #$ret = array( 'required' );
 3743+ $ret = array();
37333744
37343745 # We can't actually do this right now, because Opera 9.6 will print out
37353746 # the entered password visibly in its error message! When other

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r67283(bug 23769) Disable HTML5 form validation for now...simetrical17:18, 3 June 2010

Status & tagging log