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

[Form validation] Wrong radio behavior #5967

Closed
kevinresol opened this issue Nov 22, 2017 · 1 comment
Closed

[Form validation] Wrong radio behavior #5967

kevinresol opened this issue Nov 22, 2017 · 1 comment

Comments

@kevinresol
Copy link

kevinresol commented Nov 22, 2017

As mentioned in this comment.

The code reads:

  • if the result value is not set, set it to (isChecked) ? true : false

Two problems here

  1. since the code will set the value if it is not set, so everything is only relevant in the first iteration
  2. the ternary operation is meaningless, isChecked is already the boolean

But the bigger problem is that, it doesn't tell which radio box is checked.
Before that particular commit, the field obj returned should hold the value (.val()) of the checked radio box. After that, however, the value is a boolean which is the checked state of the first radio in the group.

@kevinresol
Copy link
Author

Sorry, duplicate of #5713

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

No branches or pull requests

1 participant