Sha256: 11263de27a4776cec0758613197ffce3ed302b1eb7a2fb0295bb098d2511a8a5
Contents?: true
Size: 519 Bytes
Versions: 3
Compression:
Stored size: 519 Bytes
Contents
require 'ixtlan/babel/serializer' module Ixtlan module Babel class NoTimestampSerializer < Serializer def self.add_defaults(root = nil) self.root root add_context(:default) add_no_timestamp_context(:collection) end def self.add_no_timestamp_context(key, options = {}) except = (options[:except] || []).dup except << :updated_at except << :created_at add_context(key, options.merge({:except => except})) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems