aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManuel Menezes de Sequeira <MMSequeira@gmail.com>2011-10-05 11:59:47 +0100
committerManuel Menezes de Sequeira <MMSequeira@gmail.com>2011-10-05 11:59:47 +0100
commit34ed93931dcf688bc4f0f8f5649a44f2f1118a6a (patch)
treee159d7da33adb7012dd523c09d95a7d4d191affb
parent4406bbe147f87cd3086076ee1544830d0c8c88b3 (diff)
parenta44bbfc1c7edb044ed9f73c7365a3a4a30b8b3fc (diff)
downloadrails-34ed93931dcf688bc4f0f8f5649a44f2f1118a6a.tar.gz
rails-34ed93931dcf688bc4f0f8f5649a44f2f1118a6a.tar.bz2
rails-34ed93931dcf688bc4f0f8f5649a44f2f1118a6a.zip
Merge branch 'master' of github.com:lifo/docrails
-rw-r--r--activemodel/lib/active_model/serializers/json.rb4
-rw-r--r--railties/guides/source/active_record_validations_callbacks.textile4
2 files changed, 4 insertions, 4 deletions
diff --git a/activemodel/lib/active_model/serializers/json.rb b/activemodel/lib/active_model/serializers/json.rb
index 885964633f..c845440120 100644
--- a/activemodel/lib/active_model/serializers/json.rb
+++ b/activemodel/lib/active_model/serializers/json.rb
@@ -15,7 +15,7 @@ module ActiveModel
self.include_root_in_json = true
end
- # Returns a JSON string representing the model. Some configuration can be
+ # Returns a hash representing the model. Some configuration can be
# passed through +options+.
#
# The option <tt>include_root_in_json</tt> controls the top-level behavior
@@ -42,7 +42,7 @@ module ActiveModel
# The remainder of the examples in this section assume include_root_in_json is set to
# <tt>false</tt>.
#
- # Without any +options+, the returned JSON string will include all the model's
+ # Without any +options+, the returned Hash will include all the model's
# attributes. For example:
#
# user = User.find(1)
diff --git a/railties/guides/source/active_record_validations_callbacks.textile b/railties/guides/source/active_record_validations_callbacks.textile
index d1b50d5dda..600681ddd3 100644
--- a/railties/guides/source/active_record_validations_callbacks.textile
+++ b/railties/guides/source/active_record_validations_callbacks.textile
@@ -105,7 +105,7 @@ Person.create(:name => "John Doe").valid? # => true
Person.create(:name => nil).valid? # => false
</ruby>
-After Active Record performing validations, any errors found can be accessed through the +errors+ instance method, which returns a collection of errors. By definition an object is valid if this collection is empty after running validations.
+After Active Record has performed validations, any errors found can be accessed through the +errors+ instance method, which returns a collection of errors. By definition, an object is valid if this collection is empty after running validations.
Note that an object instantiated with +new+ will not report errors even if it's technically invalid, because validations are not run when using +new+.
@@ -907,7 +907,7 @@ ActionView::Base.field_error_proc = Proc.new do |html_tag, instance|
end
</ruby>
-The result look like the following:
+The result looks like the following:
!images/validation_error_messages.png(Validation error messages)!