Module: Utopia::Extensions::TimeDateComparison
- Defined in:
- lib/utopia/extensions/date_comparisons.rb
Overview
Provides comparison operator extensions.
Instance Method Summary collapse
Instance Method Details
#<=>(other) ⇒ Object
27 28 29 30 31 32 33 |
# File 'lib/utopia/extensions/date_comparisons.rb', line 27 def <=>(other) if Date === other or DateTime === other self.to_datetime <=> other else super end end |