Don't shown red box around unconfirmed email address in preferences if authentication is disabled
Susan and Base-w in #wikimedia discovered that a red box is always shown around their email address on foundationwiki. This is because the box is shown by default - even when email address authentication is disabled. Change-Id: I0b906b23dec6018bc21a179e2cf950b705100c4c
This commit is contained in:
parent
7cf26c770d
commit
d2a5cf3580
1 changed files with 2 additions and 2 deletions
|
|
@ -409,8 +409,8 @@ class Preferences {
|
|||
|
||||
$disableEmailPrefs = false;
|
||||
|
||||
$emailauthenticationclass = 'mw-email-not-authenticated';
|
||||
if ( $wgEmailAuthentication ) {
|
||||
$emailauthenticationclass = 'mw-email-not-authenticated';
|
||||
if ( $user->getEmail() ) {
|
||||
if ( $user->getEmailAuthenticationTimestamp() ) {
|
||||
// date and time are separate parameters to facilitate localisation.
|
||||
|
|
@ -449,8 +449,8 @@ class Preferences {
|
|||
# Apply the same CSS class used on the input to the message:
|
||||
'cssclass' => $emailauthenticationclass,
|
||||
);
|
||||
$defaultPreferences['emailaddress']['cssclass'] = $emailauthenticationclass;
|
||||
}
|
||||
$defaultPreferences['emailaddress']['cssclass'] = $emailauthenticationclass;
|
||||
|
||||
if ( $wgEnableUserEmail && $user->isAllowed( 'sendemail' ) ) {
|
||||
$defaultPreferences['disablemail'] = array(
|
||||
|
|
|
|||
Loading…
Reference in a new issue