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

skip other validations if allowNull is true and value is null #498

Closed
wants to merge 1 commit into from
Closed

skip other validations if allowNull is true and value is null #498

wants to merge 1 commit into from

Conversation

tremby
Copy link
Contributor

@tremby tremby commented Mar 24, 2013

This fixes #270 and #118. I added tests (first ones I've ever written, so I hope they're okay) which pass, and no other tests were compromised.

@sdepold
Copy link
Member

sdepold commented Mar 24, 2013

uhm if I don't miss something you should check for allowNull: false

@janmeier
Copy link
Member

Pretty sure allowNull: true is correct

Perhaps you could check for the value being strictly true, but the logic seems right to me.

@sdepold
Copy link
Member

sdepold commented Mar 25, 2013

ah. now I got it.

@tremby
Copy link
Contributor Author

tremby commented Mar 26, 2013

I'm not sure there's a need to strictly check for boolean true. Checking for anything truthy would be my expected behaviour, I think. Up to the maintainers -- I can amend if need be.

@tremby
Copy link
Contributor Author

tremby commented May 5, 2013

I've just rebased this branch onto the current master.

@janmeier
Copy link
Member

janmeier commented May 9, 2013

Implemented in #601

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.

option for ignore validation on fields with 'allowNull=true'
3 participants