mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Merge pull request #42827 from jdufresne/author-id
Correct Inflector.humanize keep_id_suffix argument docs
This commit is contained in:
commit
8dab534ca8
2 changed files with 2 additions and 2 deletions
|
@ -260,7 +260,7 @@ class String
|
|||
# 'author_id'.humanize # => "Author"
|
||||
# 'author_id'.humanize(capitalize: false) # => "author"
|
||||
# '_id'.humanize # => "Id"
|
||||
# 'author_id'.humanize(keep_id_suffix: true) # => "Author Id"
|
||||
# 'author_id'.humanize(keep_id_suffix: true) # => "Author id"
|
||||
#
|
||||
# See ActiveSupport::Inflector.humanize.
|
||||
def humanize(capitalize: true, keep_id_suffix: false)
|
||||
|
|
|
@ -123,7 +123,7 @@ module ActiveSupport
|
|||
# humanize('author_id') # => "Author"
|
||||
# humanize('author_id', capitalize: false) # => "author"
|
||||
# humanize('_id') # => "Id"
|
||||
# humanize('author_id', keep_id_suffix: true) # => "Author Id"
|
||||
# humanize('author_id', keep_id_suffix: true) # => "Author id"
|
||||
#
|
||||
# If "SSL" was defined to be an acronym:
|
||||
#
|
||||
|
|
Loading…
Reference in a new issue