Sha256: f4c21875c5bbb0c98f96819f6f5dbda5edf3af4dc97c14492363bd3f13335c33

Contents?: true

Size: 236 Bytes

Versions: 15

Compression:

Stored size: 236 Bytes

Contents

module Mail
  class Part
    def to_postmark
      {}.tap do |hash|
        hash['Content'] = attachment? ? [read].pack('m') : body.to_s
        hash['ContentType'] = mime_type
        hash['Name'] = filename
      end
    end
  end
end

Version data entries

15 entries across 15 versions & 2 rubygems

Version Path
simple_postmark-0.5.1 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.5.0 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.4.4 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.4.3 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.4.2 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.4.1 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.4.0 lib/simple_postmark/mail_ext/part.rb
simple_postmark18-0.4.0 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.3.5 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.3.4 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.3.3 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.3.2 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.3 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.2 lib/simple_postmark/mail_ext/part.rb
simple_postmark-0.1 lib/simple_postmark/mail_ext/part.rb