func (t *Transmission) Validate() error {
	if t == nil {
		return errors.New("can't validate a nil transmission")
	}
	if t.Recipients == nil {
		return errors.New("transmission requires recipients")
	}
	if t.Subject == "" {
		return errors.New("transmission requires a subject")
	}
	if t.HTML == "" {
		return errors.New("transmission requires html content")
	}
	return nil
}
Validate runs sanity checks of a Transmission struct.
This is run before any email sending to ensure
there are no invalid API calls.
package mail
import (
	"errors"
)
type Transmission struct {
	Recipients  []string
	Subject     string
	HTML        string
	PlainText   string
	Attachments Attachments
}