instance method
middle_of_day
Ruby on Rails 6.0.6
Since v4.1.16Signature
middle_of_day()
Returns a new DateTime representing the middle of the day (12:00)
Source
# File activesupport/lib/active_support/core_ext/date_time/calculations.rb, line 126
def middle_of_day
change(hour: 12)
end
Defined in activesupport/lib/active_support/core_ext/date_time/calculations.rb line 126
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in DateTime