1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-18 19:40:55 +01:00

Fix issues with first-time account registration

Summary: This worked originally, but the migration broke slightly after the
config was deprecated, and there was another minor issue during setup.
This commit is contained in:
epriestley 2013-10-05 08:02:41 -07:00
parent f88a2b735d
commit 7dde01df76
2 changed files with 7 additions and 1 deletions

View file

@ -45,7 +45,7 @@ $config_map = array(
),
'PhabricatorAuthProviderPassword' => array(
'enabled' => 'auth.password-auth-enabled',
'enabled-default' => true,
'enabled-default' => false,
'registration' => false,
'type' => 'password',
'domain' => 'self',

View file

@ -442,6 +442,12 @@ final class PhabricatorAuthRegisterController
private function loadSetupAccount() {
$provider = new PhabricatorAuthProviderPassword();
$provider->attachProviderConfig(
id(new PhabricatorAuthProviderConfig())
->setShouldAllowRegistration(1)
->setShouldAllowLogin(1)
->setIsEnabled(true));
$account = $provider->getDefaultExternalAccount();
$response = null;
return array($account, $provider, $response);