Sha256: e8f6f659b01b7424196a9b31118bd0d4aeeff638538bf164cdbfe40af9826e97
Contents?: true
Size: 338 Bytes
Versions: 12
Compression:
Stored size: 338 Bytes
Contents
module Toy module Extensions module Array def to_store(value, *) value = value.respond_to?(:lines) ? value.lines : value Marshal.dump(value.to_a) end def from_store(value, *) value.nil? ? store_default : (value.class.is_a?(Array) ? value : Marshal.load(value)) end end end end
Version data entries
12 entries across 12 versions & 1 rubygems