Class: IntercomRails::DateHelper
- Inherits:
-
Object
- Object
- IntercomRails::DateHelper
- Defined in:
- lib/intercom-rails/date_helper.rb
Class Method Summary collapse
Class Method Details
.convert_dates_to_unix_timestamps(object) ⇒ Object
3 4 5 6 7 |
# File 'lib/intercom-rails/date_helper.rb', line 3 def self.(object) return Hash[object.map { |k, v| [k, (v)] }] if object.is_a?(Hash) return object.to_i if object.is_a?(Time) || object.is_a?(DateTime) object end |