Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

Conversation

@nkovacs
Copy link
Contributor

@nkovacs nkovacs commented Jul 30, 2015

Fixes #6

main.go Outdated
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can remove this since we validate at the top that at least a Body or HTMLBody is non-empty.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, but actually I think it would be better to allow both to be empty, and just create a message with an empty plain text body and no html body.
This would also be backwards compatible.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, but actually I think it would be better to allow both to be empty, and just create a message with an empty plain text body and no html body.

👍 I'm cool with that.

@jpoehls
Copy link
Owner

jpoehls commented Aug 10, 2015

Added a minor line note to check on but otherwise this looks good to me. Tests pass (we have tests finally!) -- Super excited to get this landed. Thanks for working on it!

@nkovacs
Copy link
Contributor Author

nkovacs commented Aug 10, 2015

I've set up travis on my repo, and it's panicking on go master: https://travis-ci.org/nkovacs/gophermail/jobs/74920350 Fixed, see #24

If both bodies are empty, send an empty plain text body.
The test used the multipart reader incorrectly, which broke
under go 1.7.
When reading a part, the returned `multipart.Part` should be used
as the source, not the original buffer.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants