Skip to content

LG-484 Display a message to the user when an account reset link is expired#2331

Merged
stevegsa merged 1 commit intomasterfrom
stevegsa-add-link-expired-to-account-reset
Jul 20, 2018
Merged

LG-484 Display a message to the user when an account reset link is expired#2331
stevegsa merged 1 commit intomasterfrom
stevegsa-add-link-expired-to-account-reset

Conversation

@stevegsa
Copy link
Copy Markdown
Contributor

@stevegsa stevegsa commented Jul 17, 2018

Why: Currently when a link to delete account is expired the user has no indication that the link was expired after clicking on it. Moreover when there is a pending request for account reset and the token is expired, a cancel link still shows. The user can cancel and create a new request. However we should remove the cancel link when the token expires so that they can immediately create a new request.

How: Display a flash message to the user when the token is expired. When there is a pending request check for a valid token rather than the existence of a token.

Hi! Before submitting your PR for review, and/or before merging it, please
go through the following checklist:

  • For DB changes, check for missing indexes, check to see if the changes
    affect other apps (such as the dashboard), make sure the DB columns in the
    various environments are properly populated, coordinate with devops, plan
    migrations in separate steps.

  • For route changes, make sure GET requests don't change state or result in
    destructive behavior. GET requests should only result in information being
    read, not written.

  • For encryption changes, make sure it is compatible with data that was
    encrypted with the old code.

  • For secrets changes, make sure to update the S3 secrets bucket with the
    new configs in all environments.

  • Do not disable Rubocop or Reek offenses unless you are absolutely sure
    they are false positives. If you're not sure how to fix the offense, please
    ask a teammate.

  • When reading data, write tests for nil values, empty strings,
    and invalid formats.

  • When calling redirect_to in a controller, use _url, not _path.

  • When adding user data to the session, use the user_session helper
    instead of the session helper so the data does not persist beyond the user's
    session.

  • When adding a new controller that requires the user to be fully
    authenticated, make sure to add before_action :confirm_two_factor_authenticated.

@stevegsa stevegsa changed the title Stevegsa add link expired to account reset LG-484 Display a message to the user when an account reset link is expired Jul 17, 2018
@stevegsa stevegsa force-pushed the stevegsa-add-link-expired-to-account-reset branch from 2ddcf22 to 91b56f4 Compare July 17, 2018 20:24
@stevegsa
Copy link
Copy Markdown
Contributor Author

stevegsa commented Jul 17, 2018

Screenshots:

After waiting 24 hours user gets notification with link to delete account
screen shot 2018-07-17 at 4 32 26 pm

After clicking on the link >24 hours after they receive the email: (new)
screen shot 2018-07-17 at 4 31 03 pm

If the user signs in >24 hours after receiving the email they no longer see a cancel link: (new)

screen shot 2018-07-17 at 4 35 11 pm

@stevegsa stevegsa force-pushed the stevegsa-add-link-expired-to-account-reset branch from 0601547 to 94fdf32 Compare July 17, 2018 20:50
@stevegsa stevegsa closed this Jul 18, 2018
@stevegsa stevegsa reopened this Jul 18, 2018
@stevegsa stevegsa closed this Jul 18, 2018
@stevegsa stevegsa reopened this Jul 18, 2018
@stevegsa stevegsa force-pushed the stevegsa-add-link-expired-to-account-reset branch from 927c955 to 67e1dcb Compare July 18, 2018 19:10
…pired

**Why**: Currently when a link to delete account is expired the user has no indication that the link was expired after clicking on it.  Moreover when there is a pending request for account reset and the token is expired, a cancel link still shows.  The user can cancel and create a new request.  However we should remove the cancel link when the token expires so that they can immediately create a new request.

**How**: Display a flash message to the user when the token is expired.  When there is a pending request check for a valid token rather than the existence of a token.
@stevegsa stevegsa force-pushed the stevegsa-add-link-expired-to-account-reset branch from 0803f95 to e730655 Compare July 19, 2018 15:05
Copy link
Copy Markdown
Contributor

@davemcorwin davemcorwin left a comment

Choose a reason for hiding this comment

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

LGTM

@stevegsa stevegsa merged commit d1c691b into master Jul 20, 2018
@amathews-fs amathews-fs deleted the stevegsa-add-link-expired-to-account-reset branch January 7, 2021 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants