mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
Fixed misleading docs for String#to_formatted_s(:db)
This commit is contained in:
@@ -39,10 +39,10 @@ class Array
|
||||
#
|
||||
# Blog.all.to_formatted_s # => "First PostSecond PostThird Post"
|
||||
#
|
||||
# Adding in the <tt>:db</tt> argument as the format yields a prettier
|
||||
# output:
|
||||
# Adding in the <tt>:db</tt> argument as the format yields a comma separated
|
||||
# id list:
|
||||
#
|
||||
# Blog.all.to_formatted_s(:db) # => "First Post,Second Post,Third Post"
|
||||
# Blog.all.to_formatted_s(:db) # => "1,2,3"
|
||||
def to_formatted_s(format = :default)
|
||||
case format
|
||||
when :db
|
||||
|
||||
Reference in New Issue
Block a user