Allow pre-encoded base64 attachments.
Attachments I receive are already encoded, so I end up decoding them before attaching them.
@krolaw, another good catch! I'll be thinking about how/if to approach fixing this. Perhaps I can include a boolean value to determine whether or not to encode the contents of the email. However, with this being a limited use-case, I may leave the API as is for simplicity.
Let me look at a couple possible designs, and I'll be back in touch shortly. Thanks for the suggestion!
I see it's a bit more complicated as you are also wrapping at the same time (my data is not wrapped). An exposed 'wrapper' function would be awesome.
One potentially breaking solution is to encode the attachment when it is added instead of when it is sent. (This would be more efficient when bulk emailing.) That way I could add the attachment manually without using the Attach().