Could not authorize you from Ldapmain because "Undefined method `provider' for nil:nilclass".
If you have an existing user that logs in via LDAP and that users group changes then the following error is shown when attempting to log in:
Could not authorize you from Ldapmain because "Undefined method
provider' for nil:nilclass".`
In the error log you can see GitLab is trying to create a new user with an email that already exists, which fails.