1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-22 14:52:41 +01:00

Extract ldap auth from password auth completely

This commit is contained in:
linead 2012-06-25 10:48:36 +10:00 committed by epriestley
parent bedc9acf98
commit e683236793

View file

@ -77,14 +77,14 @@ final class PhabricatorLoginController
$password_auth = PhabricatorEnv::getEnvConfig('auth.password-auth-enabled');
$forms = array();
$username_or_email = $request->getCookie('phusr');
$forms = array();
$errors = array();
if ($password_auth) {
$require_captcha = false;
$e_captcha = true;
$username_or_email = $request->getCookie('phusr');
if ($request->isFormPost()) {
if (AphrontFormRecaptchaControl::isRecaptchaEnabled()) {
@ -188,6 +188,8 @@ final class PhabricatorLoginController
// $panel->setCreateButton('Register New Account', '/login/register/');
$forms['Phabricator Login'] = $form;
}
$ldap_provider = new PhabricatorLDAPProvider();
if ($ldap_provider->isProviderEnabled()) {
$ldap_form = new AphrontFormView();
@ -211,7 +213,6 @@ final class PhabricatorLoginController
$forms['LDAP Login'] = $ldap_form;
}
}
$providers = PhabricatorOAuthProvider::getAllProviders();
foreach ($providers as $provider) {