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

103996 - Update custom signature validator to account for whitespace - form 10-7959c #34940

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

michaelclement
Copy link
Contributor

@michaelclement michaelclement commented Feb 26, 2025

Are you removing, renaming or moving a folder in this PR?

  • No, I'm not changing any folders (skip to TeamSites and delete the rest of this section)
  • Yes, I'm removing, renaming or moving a folder

Did you change site-wide styles, platform utilities or other infrastructure?

Summary

This PR fixes a bug with the custom signature validator in form 10-7959c. Previously, if any of the name fields included whitespace, the validator would not strip the whitespace out which led to confusing error messages if a user had, for example, a double-name like "John David".

Related issue(s)

Testing done

  • Manual
  • Unit

Screenshots

Before After
Desktop error Screenshot 2025-02-26 at 16 24 21

What areas of the site does it impact?

IVC CHAMPVA form 10-7959c only

Acceptance criteria

Quality Assurance & Testing

  • I fixed|updated|added unit tests and integration tests for each feature (if applicable).
  • No sensitive information (i.e. PII/credentials/internal URLs/etc.) is captured in logging, hardcoded, or specs
  • Linting warnings have been addressed
  • Documentation has been updated (link to documentation *if necessary)
  • Screenshot of the developed feature is added
  • Accessibility testing has been performed

Error Handling

  • Browser console contains no warnings or errors.
  • Events are being sent to the appropriate logging solution
  • Feature/bug has a monitor built into Datadog or Grafana (if applicable)

Authentication

  • Did you login to a local build and verify all authenticated routes work as expected with a test user

Requested Feedback

NA

@michaelclement michaelclement changed the title Update custom attestation for 107959c to account for whitespace 103996 - Update custom signature validator to account for whitespace - form 10-7959c Feb 26, 2025
Comment on lines +31 to 33
.replaceAll(' ', '')
.toLowerCase();
if (signatureName.replaceAll(' ', '').toLowerCase() !== name) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Previously, the function ran replaceAll(' ', '') on the signatureNamevalue, but not on the actualapplicantName` property. Now it is consistent across both values so the comparison is accurate.

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