mirror of
https://github.com/mjl-/mox.git
synced 2025-07-14 03:34:37 +03:00
use shorter smtp.NewAddress() instead of smtp.Address{...}
This commit is contained in:
@ -107,7 +107,7 @@ func ExampleComposer() {
|
||||
}()
|
||||
|
||||
// Add an address header.
|
||||
xc.HeaderAddrs("From", []message.NameAddress{{DisplayName: "Charlie", Address: smtp.Address{Localpart: "root", Domain: dns.Domain{ASCII: "localhost"}}}})
|
||||
xc.HeaderAddrs("From", []message.NameAddress{{DisplayName: "Charlie", Address: smtp.NewAddress("root", dns.Domain{ASCII: "localhost"})}})
|
||||
|
||||
// Add subject header, with encoding
|
||||
xc.Subject("hi ☺")
|
||||
|
Reference in New Issue
Block a user