diff --git a/gomail.go b/gomail.go index f491a5e..9f96b62 100644 --- a/gomail.go +++ b/gomail.go @@ -68,7 +68,7 @@ type MessageSetting func(msg *Message) // // Example: // -// msg := NewMessage(SetCharset("ISO-8859-1")) +// msg := gomail.NewMessage(SetCharset("ISO-8859-1")) func SetCharset(charset string) MessageSetting { return func(msg *Message) { msg.charset = charset @@ -79,7 +79,7 @@ func SetCharset(charset string) MessageSetting { // // Example: // -// msg := NewMessage(SetEncoding(gomail.Base64)) +// msg := gomail.NewMessage(SetEncoding(gomail.Base64)) func SetEncoding(enc Encoding) MessageSetting { return func(msg *Message) { msg.encoding = enc diff --git a/mailer.go b/mailer.go index 81ceb42..1c5ec1f 100644 --- a/mailer.go +++ b/mailer.go @@ -27,7 +27,7 @@ type MailerSetting func(m *Mailer) // myFunc := func(addr string, a smtp.Auth, from string, to []string, msg []byte) error { // // Implement your email-sending function similar to smtp.SendMail // } -// mailer := NewMailer("host", "username", "password", 25, SetSendMail(myFunc)) +// mailer := gomail.NewMailer("host", "user", "pwd", 465, SetSendMail(myFunc)) func SetSendMail(s SendMailFunc) MailerSetting { return func(m *Mailer) { m.send = s