Index: trunk/extensions/LdapAuthentication/LdapAuthentication.php |
— | — | @@ -387,6 +387,7 @@ |
388 | 388 | global $wgLDAPDomainNames, $wgLDAPUseLocal; |
389 | 389 | global $wgLDAPAddLDAPUsers; |
390 | 390 | global $wgLDAPAutoAuthDomain; |
| 391 | + global $wgLDAPMailPassword; |
391 | 392 | |
392 | 393 | $this->printDebug( "Entering modifyUITemplate", NONSENSITIVE ); |
393 | 394 | |
— | — | @@ -395,7 +396,12 @@ |
396 | 397 | } |
397 | 398 | |
398 | 399 | $template->set( 'usedomain', true ); |
399 | | - $template->set( 'useemail', false ); |
| 400 | + |
| 401 | + if ( isset( $wgLDAPMailPassword ) && $wgLDAPMailPassword[$_SESSION['wsDomain']] ) { |
| 402 | + $template->set( 'useemail', true ); |
| 403 | + } else { |
| 404 | + $template->set( 'useemail', false ); |
| 405 | + } |
400 | 406 | |
401 | 407 | $tempDomArr = $wgLDAPDomainNames; |
402 | 408 | if ( $wgLDAPUseLocal ) { |