Skip to content

PM-1531 Fix: Trim form values before submit#1164

Merged
kkartunov merged 1 commit intodevfrom
PM-1531
Jul 31, 2025
Merged

PM-1531 Fix: Trim form values before submit#1164
kkartunov merged 1 commit intodevfrom
PM-1531

Conversation

@himaniraghav3
Copy link
Collaborator

Related JIRA Ticket:

https://topcoder.atlassian.net/browse/PM-1531

What's in this PR?

Trim form values so that blank space is not counted as character during validation

@himaniraghav3 himaniraghav3 requested a review from kkartunov July 30, 2025 07:22
message: 'Number of hours per week should be a positive number',
},
{
condition: formValues.otherPaymentType && formValues.otherPaymentType.trim().length === 0,

Choose a reason for hiding this comment

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

Consider checking if formValues.otherPaymentType is a string before calling trim() to avoid potential runtime errors if the value is not a string.

@kkartunov kkartunov merged commit 94afdd5 into dev Jul 31, 2025
3 checks passed
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