Module: NullAttributeReplacer

Defined in:
app/serializers/null_attribute_replacer.rb

Instance Method Summary collapse

Instance Method Details

#serializable_hash(adapter_options = nil, options = {}, adapter_instance = self.class.serialization_adapter_instance) ⇒ Object



2
3
4
5
6
# File 'app/serializers/null_attribute_replacer.rb', line 2

def serializable_hash(adapter_options = nil, options = {}, adapter_instance = self.class.serialization_adapter_instance)
  hash = super
  hash.each { |key, value| hash[key] = "" if value.nil? }
  hash
end