go-ozzo / ozzo-validation

An idiomatic Go (golang) validation package. Supports configurable and extensible validation rules (validators) using normal language constructs instead of error-prone struct tags.
MIT License
3.73k stars 224 forks source link

How to validate a boolean field #190

Open odannyc opened 10 months ago

odannyc commented 10 months ago

I'd like to validate that a boolean field is required to be false. -- null and true should fail validation.

How do I go about doing this?