提交 4e1dc112 编写于 作者: M Max Kramer

Rename options param of #time_ago_in_words to match API change

Rename `include_seconds_or_options` to `options` to match 6b9356a4 (which removed the deprecation introduced by #6077).  This has no functional impact because the parameter is passed directly through, but makes it clearer that the parameter no longer supports a boolean as input.
上级 b44174f8
......@@ -153,8 +153,8 @@ def distance_of_time_in_words(from_time, to_time = 0, options = {})
#
# Note that you cannot pass a <tt>Numeric</tt> value to <tt>time_ago_in_words</tt>.
#
def time_ago_in_words(from_time, include_seconds_or_options = {})
distance_of_time_in_words(from_time, Time.now, include_seconds_or_options)
def time_ago_in_words(from_time, options = {})
distance_of_time_in_words(from_time, Time.now, options)
end
alias_method :distance_of_time_in_words_to_now, :time_ago_in_words
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册