mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
removed erroneous line. Corrected presence validation example.
Addresses #20343. Removes erroneous line of code in the sample codeblock.
This commit is contained in:
parent
0920576610
commit
d30f0011a9
1 changed files with 0 additions and 1 deletions
|
@ -552,7 +552,6 @@ Since `false.blank?` is true, if you want to validate the presence of a boolean
|
||||||
field you should use one of the following validations:
|
field you should use one of the following validations:
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
validates :boolean_field_name, presence: true
|
|
||||||
validates :boolean_field_name, inclusion: { in: [true, false] }
|
validates :boolean_field_name, inclusion: { in: [true, false] }
|
||||||
validates :boolean_field_name, exclusion: { in: [nil] }
|
validates :boolean_field_name, exclusion: { in: [nil] }
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in a new issue