Sha256: a5f7b531562989b7b7e049a9c11faea0fb6cb6e939337b754120cd9c8812b66c
Contents?: true
Size: 433 Bytes
Versions: 11
Compression:
Stored size: 433 Bytes
Contents
module Ddr::Models class AttachedFilesProfile include ActiveModel::Serializers::JSON attr_reader :object def initialize(object) @object = object end def attributes files.keys.map { |k| [k, nil] }.to_h end def read_attribute_for_serialization(key) AttachedFileProfile.new(files[key]) end private def files object.attached_files_having_content end end end
Version data entries
11 entries across 11 versions & 1 rubygems