mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix typo in validations documentation. Closes #7669. [ee]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6301 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
parent
1dc56ba481
commit
bda4009aee
1 changed files with 2 additions and 2 deletions
|
@ -452,10 +452,10 @@ module ActiveRecord
|
|||
# === Warning
|
||||
# Validate the presence of the foreign key, not the instance variable itself.
|
||||
# Do this:
|
||||
# validate_presence_of :invoice_id
|
||||
# validates_presence_of :invoice_id
|
||||
#
|
||||
# Not this:
|
||||
# validate_presence_of :invoice
|
||||
# validates_presence_of :invoice
|
||||
#
|
||||
# If you validate the presence of the associated object, you will get
|
||||
# failures on saves when both the parent object and the child object are
|
||||
|
|
Loading…
Reference in a new issue