*/
protected function checkRegistrationAllowed()
{
- if (!setting('registration-enabled')) {
+ if (!setting('registration-enabled') || config('auth.method') === 'ldap') {
throw new UserRegistrationException(trans('auth.registrations_disabled'), '/login');
}
}