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

The isValid method throws if the form does not contain any validation attributes #104

Closed
derTuca opened this issue Mar 25, 2024 · 3 comments · Fixed by #105
Closed

The isValid method throws if the form does not contain any validation attributes #104

derTuca opened this issue Mar 25, 2024 · 3 comments · Fixed by #105
Assignees

Comments

@derTuca
Copy link

derTuca commented Mar 25, 2024

Hi,

I am using a function that calls ValidationService.isValid on every page on my site, but some pages do not have any validated fields. When called on a form with no fields that have validation, I would expect the return value to be true. Instead, the method throws on this line: var invalidFormInputUIDs = formInputUIDs.filter(...) with the error formInputUIDs is undefined.

@dahlbyk dahlbyk self-assigned this Mar 27, 2024
@dahlbyk
Copy link
Collaborator

dahlbyk commented Mar 27, 2024

You're absolutely right. PR incoming.

@dahlbyk
Copy link
Collaborator

dahlbyk commented Mar 27, 2024

@derTuca I'm pretty confident, but feel free to give #105 a try.

@dahlbyk
Copy link
Collaborator

dahlbyk commented Mar 27, 2024

Fix shipped in https://www.npmjs.com/package/aspnet-client-validation/v/0.9.6, please let us know if you still see an issue.

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 a pull request may close this issue.

2 participants