Class: Date
- Inherits:
-
Object
- Object
- Date
- Defined in:
- lib/weekly_calendar/helpers.rb
Instance Method Summary collapse
Instance Method Details
#same_day_as?(date_or_time) ⇒ Boolean
2 3 4 5 6 7 8 |
# File 'lib/weekly_calendar/helpers.rb', line 2 def same_day_as?(date_or_time) if date_or_time.is_a?(Time) date_or_time.yday == self.yday && date_or_time.year == self.year else self == date_or_time end end |