-
Notifications
You must be signed in to change notification settings - Fork 14
Fyst 1730 strip any values that are not allowed from middle initial field #5478
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
Fyst 1730 strip any values that are not allowed from middle initial field #5478
Conversation
…rect_file_data to sanitize the initial
Heroku app: https://gyr-review-app-5478-39c36265b2b8.herokuapp.com/ |
@@ -19,7 +19,7 @@ def document | |||
xml.Dependent do | |||
xml.Name do | |||
xml.FirstName sanitize_for_xml(dependent.first_name, 16) | |||
xml.MiddleInitial sanitize_for_xml(dependent.middle_initial, 1) if dependent.middle_initial.present? | |||
xml.MiddleInitial sanitize_middle_initial(dependent.middle_initial) if sanitize_middle_initial(dependent.middle_initial).present? |
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.
lines 185 and 189 also have xml.MiddleInitial
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.
I did not sanitize account_holder_middle_initial b/c this is input through intake & we validate this field.
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.
sorry for missing the coment!
@@ -31,7 +31,7 @@ def document | |||
xml.SpouseSSN intake.spouse.ssn | |||
xml.SpouseName do | |||
xml.FirstName sanitize_for_xml(intake.spouse.first_name) | |||
xml.MiddleInitial sanitize_for_xml(intake.spouse.middle_initial) if intake.spouse.middle_initial.present? | |||
xml.MiddleInitial sanitize_middle_initial(intake.spouse.middle_initial) if sanitize_middle_initial(intake.spouse.middle_initial).present? |
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.
line 100 (the dependents block) also has xml.MiddleInitial
…-that-are-not-allowed-from-middle-initial-field
Link to pivotal/JIRA issue
Is PM acceptance required? (delete one)
Reminder: merge main into this branch and get green tests before merging to main
What was done?
sanitize_for_xml
) first to without limiting length to 1 incase an acceptable letter was somehow provided for this field, then after rejecting unacceptable characters, limit to 1direct_file_data
(notably: I did not sanitizeaccount_holder_middle_initial
b/c this is input through intake & we validate this field.How to test?
Screenshots (for visual changes)