Sha256: 4c92c2d9ff133640498b61dd18e3133bc68801bd9ad38270f31234c990dbf9e3
Contents?: true
Size: 362 Bytes
Versions: 32
Compression:
Stored size: 362 Bytes
Contents
# # Utility methods that alleviate the pain of dealign with timezones, midnight, etc... # class Sundial def self.in_time_zone(organization, time_string) ActiveSupport::TimeZone.create(organization.time_zone).parse(time_string) end def self.midnightish(organization, time_string) in_time_zone(organization, time_string) + 1.day - 1.minute end end
Version data entries
32 entries across 32 versions & 1 rubygems