aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib
diff options
context:
space:
mode:
authorCarlos Antonio da Silva <carlosantoniodasilva@gmail.com>2012-01-25 09:31:00 -0200
committerCarlos Antonio da Silva <carlosantoniodasilva@gmail.com>2012-01-25 16:36:27 -0200
commiteb171fa328242ce355c9f6f8240cefb146115931 (patch)
tree4026e123ebfd048998d1edaae3ae6c68ab4c39f9 /activesupport/lib
parent6a85c45b1cced856da3377fe1eb50b1f8436cb9e (diff)
downloadrails-eb171fa328242ce355c9f6f8240cefb146115931.tar.gz
rails-eb171fa328242ce355c9f6f8240cefb146115931.tar.bz2
rails-eb171fa328242ce355c9f6f8240cefb146115931.zip
Change ActiveRecord::Errors to ActiveModel::Errors in guides
Use ActiveModel::Errors in inflection example docs as well. Also fixes wrong information and link to locale file related to Errors#full_messages in I18n guide.
Diffstat (limited to 'activesupport/lib')
-rw-r--r--activesupport/lib/active_support/core_ext/string/inflections.rb4
-rw-r--r--activesupport/lib/active_support/inflector/methods.rb12
2 files changed, 8 insertions, 8 deletions
diff --git a/activesupport/lib/active_support/core_ext/string/inflections.rb b/activesupport/lib/active_support/core_ext/string/inflections.rb
index 1e57b586d9..2194dafe4d 100644
--- a/activesupport/lib/active_support/core_ext/string/inflections.rb
+++ b/activesupport/lib/active_support/core_ext/string/inflections.rb
@@ -100,8 +100,8 @@ class String
#
# +underscore+ will also change '::' to '/' to convert namespaces to paths.
#
- # "ActiveRecord".underscore # => "active_record"
- # "ActiveRecord::Errors".underscore # => active_record/errors
+ # "ActiveModel".underscore # => "active_model"
+ # "ActiveModel::Errors".underscore # => "active_model/errors"
def underscore
ActiveSupport::Inflector.underscore(self)
end
diff --git a/activesupport/lib/active_support/inflector/methods.rb b/activesupport/lib/active_support/inflector/methods.rb
index 144cdd3c8f..c68a2baee7 100644
--- a/activesupport/lib/active_support/inflector/methods.rb
+++ b/activesupport/lib/active_support/inflector/methods.rb
@@ -42,10 +42,10 @@ module ActiveSupport
# +camelize+ will also convert '/' to '::' which is useful for converting paths to namespaces.
#
# Examples:
- # "active_record".camelize # => "ActiveRecord"
- # "active_record".camelize(:lower) # => "activeRecord"
- # "active_record/errors".camelize # => "ActiveRecord::Errors"
- # "active_record/errors".camelize(:lower) # => "activeRecord::Errors"
+ # "active_model".camelize # => "ActiveModel"
+ # "active_model".camelize(:lower) # => "activeModel"
+ # "active_model/errors".camelize # => "ActiveModel::Errors"
+ # "active_model/errors".camelize(:lower) # => "activeModel::Errors"
#
# As a rule of thumb you can think of +camelize+ as the inverse of +underscore+,
# though there are cases where that does not hold:
@@ -66,8 +66,8 @@ module ActiveSupport
# Changes '::' to '/' to convert namespaces to paths.
#
# Examples:
- # "ActiveRecord".underscore # => "active_record"
- # "ActiveRecord::Errors".underscore # => active_record/errors
+ # "ActiveModel".underscore # => "active_model"
+ # "ActiveModel::Errors".underscore # => "active_model/errors"
#
# As a rule of thumb you can think of +underscore+ as the inverse of +camelize+,
# though there are cases where that does not hold: