FIX: Show invite validation errors to users (#12717)

The server used to respond with a generic 'error, contact admin' message
which did not offer any hint what the error was. This happened even when
the error could be easily corrected by the user (for example, if they
chose a very common password).
This commit is contained in:
Dan Ungureanu
2021-04-15 15:23:49 +03:00
committed by GitHub
parent 4d87360f84
commit bfa301bd7b
3 changed files with 1 additions and 5 deletions

View File

@ -443,7 +443,6 @@ describe InvitesController do
it 'does not log in the user if there are validation errors' do
put "/invites/show/#{invite.invite_key}.json", params: { password: 'password' }
expect(response.status).to eq(412)
expect(response.parsed_body['errors']['password']).to be_present
end
it 'fails when local login is disabled and no external auth is configured' do