diff options
author | Yuichiro Suzuki <u16suzu@gmail.com> | 2012-12-20 01:20:05 +0900 |
---|---|---|
committer | Yuichiro Suzuki <u16suzu@gmail.com> | 2012-12-20 01:20:05 +0900 |
commit | f12d09f97fb54acb0a44eebbc049b4e30318634a (patch) | |
tree | a8574f7b4b384396ad2fa5f4ce591c70752b9204 | |
parent | 4d2d0d9906f16a1255e10d55530907318b281c3e (diff) | |
download | rails-f12d09f97fb54acb0a44eebbc049b4e30318634a.tar.gz rails-f12d09f97fb54acb0a44eebbc049b4e30318634a.tar.bz2 rails-f12d09f97fb54acb0a44eebbc049b4e30318634a.zip |
Fix: documentation for String#humanize
-rw-r--r-- | activesupport/lib/active_support/core_ext/string/inflections.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/lib/active_support/core_ext/string/inflections.rb b/activesupport/lib/active_support/core_ext/string/inflections.rb index 2194dafe4d..3717388ace 100644 --- a/activesupport/lib/active_support/core_ext/string/inflections.rb +++ b/activesupport/lib/active_support/core_ext/string/inflections.rb @@ -182,8 +182,8 @@ class String # Capitalizes the first word, turns underscores into spaces, and strips '_id'. # Like +titleize+, this is meant for creating pretty output. # - # "employee_salary" # => "Employee salary" - # "author_id" # => "Author" + # "employee_salary".humanize # => "Employee salary" + # "author_id".humanize # => "Author" def humanize ActiveSupport::Inflector.humanize(self) end |