Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: remove existing user check from inquiry auth flow #13605

Merged
merged 8 commits into from Mar 18, 2024

Conversation

mc-jones
Copy link
Contributor

@mc-jones mc-jones commented Mar 14, 2024

The type of this PR is: Refactor

This PR solves PHIRE-670

Description

This PR removes the existing user check from the inquiry flow. See the parent of the ticket above for more detailed reasoning.

In slack, redirecting to the canonical auth flow was discussed as an option. I decided against this for the following reasons:

  1. Scope. Looking at the code I felt this would require a much more significant refactor. The goal of this PR was to remove the existing user check from this inquiry flow and I wanted to stick as close to that as possible. However, I did try to make reasonable improvements to the current flow; such as, easier navigation between auth views and updating the error handling to be more like our main Auth flow.
  2. In discussing the work with @jpoczik, I understand that we are considering a more general auth flow refactor. It felt reasonable to avoid integrating the canonical auth flow into the inquiry flow if the work will be redone in the medium term.

Considerations

  • This work only affects the Auth portion of the inquiry flow. The post Auth steps (e.g. setting up a collector profile) have not been changed.
  • I ran this by the PMs of Diamond (Auth) and Amber (Inquiry) to make sure they are comfortable with these changes from a product perspective.
old new
Screenshot 2024-03-14 at 4 02 55 PM Screenshot 2024-03-15 at 8 35 24 AM
Screenshot 2024-03-14 at 4 03 18 PM Screenshot 2024-03-14 at 4 00 09 PM
Screenshot 2024-03-14 at 4 05 20 PM Screenshot 2024-03-14 at 4 00 44 PM
Screenshot 2024-03-14 at 4 05 39 PM Screenshot 2024-03-14 at 4 01 00 PM

@@ -12,9 +12,6 @@ export const formatErrorMessage = (error: Error) => {
case "User Already Exists":
return "An account with this email already exists."

case "User Not Found":
return "No account with this email exists."
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@mc-jones mc-jones marked this pull request as ready for review March 15, 2024 13:00
dzucconi
dzucconi previously approved these changes Mar 15, 2024
Copy link
Member

@dzucconi dzucconi left a comment

Choose a reason for hiding this comment

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

This all looks very reasonable. I appreciate the detail and the clear before/after screenshots.

@mc-jones
Copy link
Contributor Author

Assigning this PR to myself. Realized I need to push integrity changes. Will sequence the rollout once those are ready.

@mc-jones mc-jones merged commit 8420496 into main Mar 18, 2024
11 checks passed
@mc-jones mc-jones deleted the mc-jones/refactor-inquiry-auth-flow branch March 18, 2024 16:48
@artsy-peril artsy-peril bot mentioned this pull request Mar 18, 2024
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.

None yet

2 participants