aboutsummaryrefslogtreecommitdiffstats
path: root/guides/source/active_record_validations.md
diff options
context:
space:
mode:
authorZoltan Debre <zdebre@gmail.com>2013-04-16 00:56:12 +0200
committerZoltan Debre <zdebre@gmail.com>2013-04-16 00:56:12 +0200
commitffde34d51075e584658b5d492a9d2b101c5633b7 (patch)
tree3ec49e91b71670fe565410842e4a4e464713558b /guides/source/active_record_validations.md
parent1655f4142efa89acb86812f5c1d7572e51cbae80 (diff)
downloadrails-ffde34d51075e584658b5d492a9d2b101c5633b7.tar.gz
rails-ffde34d51075e584658b5d492a9d2b101c5633b7.tar.bz2
rails-ffde34d51075e584658b5d492a9d2b101c5633b7.zip
Change 'validates_presence_of' to 'presence: true'
Of course validates_presence_of is still working but it is not explained in the guide, I think consequently should use 'presence: true' in this documentation.
Diffstat (limited to 'guides/source/active_record_validations.md')
-rw-r--r--guides/source/active_record_validations.md2
1 files changed, 1 insertions, 1 deletions
diff --git a/guides/source/active_record_validations.md b/guides/source/active_record_validations.md
index df39d3c5dc..d043e42090 100644
--- a/guides/source/active_record_validations.md
+++ b/guides/source/active_record_validations.md
@@ -434,7 +434,7 @@ end
Note that the default error messages are plural (e.g., "is too short (minimum
is %{count} characters)"). For this reason, when `:minimum` is 1 you should
-provide a personalized message or use `validates_presence_of` instead. When
+provide a personalized message or use `presence: true` instead. When
`:in` or `:within` have a lower limit of 1, you should either provide a
personalized message or call `presence` prior to `length`.