Sha256: 0f68d93762c3066fe424bda8dedf1b1c8f7e4a94a70d589721bdf854a9378a21
Contents?: true
Size: 436 Bytes
Versions: 66
Compression:
Stored size: 436 Bytes
Contents
class FestivityDatetimeFilterPresenter def self.new(datetimes, datetime_type) datetimes.map { |datetime| datetime_type_class(datetime_type).new(datetime) } end def self.parse(datetimes, datetime_type) self.new(datetimes.map{|date| Chronic.parse(date)}, datetime_type) end private def self.datetime_type_class(datetime_type) datetime_type == "date" ? FestivityDatePresenter : FestivityTimePresenter end end
Version data entries
66 entries across 66 versions & 1 rubygems