lib/tins/date_dummy.rb in tins-1.3.2 vs lib/tins/date_dummy.rb in tins-1.3.3
- old
+ new
@@ -9,9 +9,11 @@
remove_method :today rescue nil
def dummy=(value)
if value.respond_to?(:to_str)
value = Date.parse(value.to_str)
+ elsif value.respond_to?(:to_date)
+ value = value.to_date
end
@dummy = value
end
def dummy(value = nil)