Method: Teasy::AmbiguousTimeHandling::ClassMethods#with_ambiguous_time_handler
- Defined in:
- lib/teasy/ambiguous_time_handling.rb
#with_ambiguous_time_handler(handler) ⇒ Object
28 29 30 31 32 33 34 |
# File 'lib/teasy/ambiguous_time_handling.rb', line 28 def with_ambiguous_time_handler(handler) old_handler = ambiguous_time_handler self.ambiguous_time_handler = handler yield ensure self.ambiguous_time_handler = old_handler end |