Checkbox acceptance validation causes checkbox to uncheck immediately #265

merged 1 commit into from Jun 15, 2012

6 participants


I did not see an appropriate branch to make this pull request against since I forked off of master and this only seems to be a problem in master.

I ran into a problem with a checkbox validator where the checking the checkbox would immediately cause the checkbox to uncheck itself. I was able to trace back the problem to not returning true from the checkbox click handler. I'm not sure why this is a problem now since it didn't look like true was forcibly returned previously either but this change fixed the problem for me.

No tests broke as a result. I did not include a test because I didn't see any browser tests and it seems like this may be a place where the existing JS testing is not enough?


+1 for this.


+1 for this, though you don't actually need to return anything at all. it's specifically the false that causes issues. note to that this is also a problem in reverse (for me anyway, using beta-3). that is, if the checkbox has been checked, and the user tries to uncheck it, the return false cancels that and the checkbox remains checked. some might see this as a "feature" ;) but i want to be sure my users accepted terms voluntarily.





@bcardarella bcardarella merged commit 9ab27ad into DavyJonesLocker:master Jun 15, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment