module Spina::Upgrade::AttachmentDecorator

Public Instance Methods

convert_to_json!() click to toggle source
# File lib/spina/upgrade/decorators/attachment_decorator.rb, line 5
def convert_to_json!
  attachment = Spina::Parts::Attachment.new
  attachment.attachment_id = id
  attachment.signed_blob_id = file&.blob&.signed_id
  attachment.filename = name
  attachment
end