sendgrid/nodemailer-sendgrid-transport — pull request #5 by andris9 (2014-07-30 12:32:05+00:00)
Title: Better compatibility with Nodemailer mail options

**NB!** Requires Nodemailer v1.1+.

* Instead of getting `from` and `to` data from the mail object (which is unparsed, might include mixed strings and arrays, formatted and unformatted addresses etc.), use parsed arrays from the message object. Fixes all issues with formatted names (eg. handles properly the following input: `'"Receiver O'Name" , receiver2@example.com'`)
* Resolves all streams, urls and file paths to strings or buffers to match the default behavior for Nodemailer. This enables advanced content handling, for example the following is supported by Nodemailer (and by this PR):

```javascript
var mail = {
text: "plain text content",
html: {
content: fs.createReadStream('path/to/html')
}
};
```