Invalid email address in forgot password request
jpslav opened this issue · comments
When users input a bad password on the forgot password screen we get:
An AWS::SES::ResponseError occurred in identities#forgot_password:
InvalidParameterValue - Local address contains control or whitespace
vendor/bundle/ruby/1.9.1/gems/aws-ses-0.6.0/lib/aws/ses/base.rb:175:in `request'
I'd recommend wrapping this code in a begin
rescue
block making sure to check that the rescued AWS::SES::ResponseError
has the message above (as other errors we might need to bubble out as exceptions). When this specific error is caught, fatal_error
with a decent message. Hopefully these messages already bubble up as flash errors to the user. Add a spec in /spec/features/forgot_password_spec.rb
, making sure to mock the deliver call so that it raises this exception.
I'm too much in bug search and destroy mode to have remembered that @karenc already knocked these out!