-
Notifications
You must be signed in to change notification settings - Fork 163
LG-15440 We couldnt find records matching your address screen #12066
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
Changes from 10 commits
24936bd
0e21062
eb5bb80
c50bb21
af96afc
4644406
594bcc4
71eb49a
c6371f8
ed2e111
2d49582
619a912
6533ff3
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -8,36 +8,37 @@ class SessionErrorsController < ApplicationController | |||||||||
|
||||||||||
before_action :confirm_two_factor_authenticated_or_user_id_in_session | ||||||||||
before_action :confirm_idv_session_step_needed | ||||||||||
before_action :set_resolution_rate_limiter, only: [:warning, :address_warning, :failure] | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
i think it's simpler to just call the rate limiter when needed ... is there a benefit to using the filter here? |
||||||||||
before_action :set_try_again_path, only: [:warning, :exception, :state_id_warning] | ||||||||||
before_action :ignore_form_step_wait_requests | ||||||||||
|
||||||||||
attr_reader :resolution_rate_limiter | ||||||||||
|
||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||
def exception | ||||||||||
log_event | ||||||||||
end | ||||||||||
|
||||||||||
def warning | ||||||||||
rate_limiter = RateLimiter.new( | ||||||||||
user: idv_session_user, | ||||||||||
rate_limit_type: :idv_resolution, | ||||||||||
) | ||||||||||
|
||||||||||
@step_indicator_steps = step_indicator_steps | ||||||||||
@remaining_submit_attempts = rate_limiter.remaining_count | ||||||||||
log_event(based_on_limiter: rate_limiter) | ||||||||||
@remaining_submit_attempts = resolution_rate_limiter.remaining_count | ||||||||||
log_event(based_on_limiter: resolution_rate_limiter) | ||||||||||
end | ||||||||||
|
||||||||||
def state_id_warning | ||||||||||
log_event | ||||||||||
end | ||||||||||
|
||||||||||
def address_warning | ||||||||||
@step_indicator_steps = step_indicator_steps | ||||||||||
@address_path = idv_address_url | ||||||||||
@remaining_submit_attempts = resolution_rate_limiter.remaining_count | ||||||||||
log_event(based_on_limiter: resolution_rate_limiter) | ||||||||||
end | ||||||||||
|
||||||||||
def failure | ||||||||||
rate_limiter = RateLimiter.new( | ||||||||||
user: idv_session_user, | ||||||||||
rate_limit_type: :idv_resolution, | ||||||||||
) | ||||||||||
@expires_at = rate_limiter.expires_at | ||||||||||
@expires_at = resolution_rate_limiter.expires_at | ||||||||||
@sp_name = decorated_sp_session.sp_name | ||||||||||
log_event(based_on_limiter: rate_limiter) | ||||||||||
log_event(based_on_limiter: resolution_rate_limiter) | ||||||||||
end | ||||||||||
|
||||||||||
def ssn_failure | ||||||||||
|
@@ -63,6 +64,13 @@ def rate_limited | |||||||||
|
||||||||||
private | ||||||||||
|
||||||||||
def set_resolution_rate_limiter | ||||||||||
@resolution_rate_limiter = RateLimiter.new( | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||
user: idv_session_user, | ||||||||||
rate_limit_type: :idv_resolution, | ||||||||||
) | ||||||||||
end | ||||||||||
|
||||||||||
def confirm_two_factor_authenticated_or_user_id_in_session | ||||||||||
return if session[:doc_capture_user_id].present? | ||||||||||
|
||||||||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<% self.title = t('titles.failure.information_not_verified') %> | ||
|
||
<% content_for(:pre_flash_content) do %> | ||
<%= render StepIndicatorComponent.new( | ||
steps: @step_indicator_steps, | ||
current_step: :verify_info, | ||
locale_scope: 'idv', | ||
class: 'margin-x-neg-2 margin-top-neg-4 tablet:margin-x-neg-6 tablet:margin-top-neg-4', | ||
) %> | ||
<% end %> | ||
|
||
<%= render StatusPageComponent.new(status: :warning) do |c| %> | ||
<% c.with_header { t('idv.warning.address.heading') } %> | ||
|
||
<p><%= t('idv.failure.address.warning') %></p> | ||
<p><%= t('idv.failure.attempts_html', count: @remaining_submit_attempts) %></p> | ||
|
||
<% c.with_action_button( | ||
url: @address_path, | ||
class: 'margin-bottom-2', | ||
) { t('idv.forgot_password.try_again') } %> | ||
<% end %> | ||
|
||
<%= render PageFooterComponent.new do %> | ||
<%= link_to t('links.cancel'), idv_cancel_path(step: :invalid_session) %> | ||
<% end %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we know that address is the sole error?