Skip to content

Fix error on bad password during password verification#4551

Merged
mitchellhenke merged 2 commits intomasterfrom
mitchellhenke/fix-verify-password-error
Jan 4, 2021
Merged

Fix error on bad password during password verification#4551
mitchellhenke merged 2 commits intomasterfrom
mitchellhenke/fix-verify-password-error

Conversation

@mitchellhenke
Copy link
Contributor

@verify_password_form is expected to be defined to render :new, but the instance variable is never set in the update call.

This results in an error if the form validation fails: New Relic error

The template uses @verify_password_form strictly for the pii, so I moved the variable assignment up and out of the template and explicitly pass in @decrypted_pii now.

The test also unexpectedly passes because controller specs do not render the view, and enabling view rendering causes the spec to fail.

Copy link
Contributor

@zachmargolis zachmargolis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's this for?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops unrelated, removing

@mitchellhenke mitchellhenke force-pushed the mitchellhenke/fix-verify-password-error branch from 1dc3153 to 69c434c Compare January 4, 2021 16:25
@mitchellhenke mitchellhenke merged commit 7aaa1bf into master Jan 4, 2021
@mitchellhenke mitchellhenke deleted the mitchellhenke/fix-verify-password-error branch January 4, 2021 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants