提交 e3b59c71 编写于 作者: J José Valim

Merge pull request #4184 from lest/remove-1-8-code

remove date methods that are present in 1.9 ruby
......@@ -136,26 +136,6 @@ def years_since(years)
advance(:years => years)
end
# Shorthand for years_ago(1)
def prev_year
years_ago(1)
end unless method_defined?(:prev_year)
# Shorthand for years_since(1)
def next_year
years_since(1)
end unless method_defined?(:next_year)
# Shorthand for months_ago(1)
def prev_month
months_ago(1)
end unless method_defined?(:prev_month)
# Shorthand for months_since(1)
def next_month
months_since(1)
end unless method_defined?(:next_month)
# Returns number of days to start of this week. Week is assumed to start on
# +start_day+, default is +:monday+.
def days_to_week_start(start_day = :monday)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册