lib/mandrill_dm/message.rb
# Returns a Mandrill API compatible attachment hash
Returns a Mandrill API compatible attachment hash
Returns a Mandrill API compatible attachment hash
def attachments
      return nil unless mail.attachments.any?
      mail.attachments.collect do |attachment|
        {
          name: attachment.filename,
          type: attachment.mime_type,
          content: Base64.encode64(attachment.body.decoded)
        }
      end
    end
def attachments return nil unless mail . attachments . any? mail . attachments . collect do | attachment | { name : attachment . filename , type : attachment . mime_type , content : Base64 . encode64 ( attachment . body . decoded ) } end end
Returns a Mandrill API compatible attachment hash
Returns a Mandrill API compatible attachment hash