Class: Duststorm::Attribute::Time

Inherits:
Virtus::Attribute
  • Object
show all
Defined in:
lib/duststorm/attribute/time.rb

Instance Method Summary collapse

Instance Method Details

#coerce(value) ⇒ Object



4
5
6
7
# File 'lib/duststorm/attribute/time.rb', line 4

def coerce(value)
  return unless value
  ::Time.at(value)
end