Skip to content

Use the verify profile concern to sort through all of the reasons a user may be pending#8468

Merged
jmhooper merged 1 commit intomainfrom
jmhooper-use-pending-profile-concern
May 24, 2023
Merged

Use the verify profile concern to sort through all of the reasons a user may be pending#8468
jmhooper merged 1 commit intomainfrom
jmhooper-use-pending-profile-concern

Conversation

@jmhooper
Copy link
Contributor

We have made changes to the pending_profile concept in the IdP. Previously a profile was pending if the user was waiting on GPO verification. We have added more out of band flows which result in more pending reasons:

  1. GPO Verification
  2. Fraud review
  3. In-person proofing

This logic got spread throughout the codebase in ways that were often kind of tough to follow. This led to lots of bugs trying to send the user to the right place to finish proofing.

This commit collects that logic in the VerifyProfileConcern. This was chosen because this is where much of the logic for the GPO confirmation flow lived already.

@jmhooper
Copy link
Contributor Author

This is still work in progress. There is a lot of work left to sort out the SAML and OIDC controllers.

@jmhooper jmhooper marked this pull request as ready for review May 23, 2023 19:13
@jmhooper jmhooper requested a review from a team May 23, 2023 19:13
@jmhooper
Copy link
Contributor Author

Okay, I think I have the OIDC and SAML controller in shape. This is ready for review.

Copy link
Contributor

Choose a reason for hiding this comment

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

Is it worth trying to move away from the generic "has pending profile"? If we wanted to, we could take a small shortcut and replace the conditionals used with:

Suggested change
return url_for_pending_profile_reason if user_has_pending_profile?
return url_for_pending_profile_reason if url_for_pending_profile_reason

It looks like the method would still be used by some analytics, but it might be worth splitting that up to be more specific too.

Copy link
Contributor

Choose a reason for hiding this comment

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

Much easier to read 😀

Base automatically changed from jmhooper-untangle-backup-code-reminder-from-pending-profile to main May 24, 2023 15:15
…ser may be pending

We have made changes to the `pending_profile` concept in the IdP. Previously a profile was pending if the user was waiting on GPO verification. We have added more out of band flows which result in more pending reasons:

1. GPO Verification
2. Fraud review
3. In-person proofing

This logic got spread throughout the codebase in ways that were often kind of tough to follow. This led to lots of bugs trying to send the user to the right place to finish proofing.

This commit collects that logic in the `VerifyProfileConcern`. This was chosen because this is where much of the logic for the GPO confirmation flow lived already.

[skip changelog]
@jmhooper jmhooper force-pushed the jmhooper-use-pending-profile-concern branch from 578ba63 to a74354a Compare May 24, 2023 15:16
@jmhooper jmhooper merged commit 1c10b71 into main May 24, 2023
@jmhooper jmhooper deleted the jmhooper-use-pending-profile-concern branch May 24, 2023 16:34
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