Class: Redis::Attrs::Date
Instance Attribute Summary
Attributes inherited from Base
#klass, #name, #options, #type
Instance Method Summary collapse
Methods inherited from Scalar
Methods inherited from Base
#initialize, #redis, #redis_key
Constructor Details
This class inherits a constructor from Redis::Attrs::Scalar
Instance Method Details
#deserialize(value) ⇒ Object
4 5 6 |
# File 'lib/redis-attrs/date.rb', line 4 def deserialize(value) value.nil? ? nil : ::Date.parse(value) end |