mirror of
https://github.com/golang/go
synced 2024-11-23 18:50:05 -07:00
net/mail: fix build.
Change-Id: I8f5c72c6c0db015c06d564523bab35d97d934578 Reviewed-on: https://go-review.googlesource.com/13510 Reviewed-by: Michael McGreevy <mcgreevy@golang.org> Reviewed-by: David Symonds <dsymonds@golang.org>
This commit is contained in:
parent
1d75b40de8
commit
1052b43213
@ -177,7 +177,7 @@ func (a *Address) String() string {
|
||||
// treat the whole address as local-part.
|
||||
local = a.Address
|
||||
} else {
|
||||
local, domain := a.Address[:at], a.Address[at+1:]
|
||||
local, domain = a.Address[:at], a.Address[at+1:]
|
||||
}
|
||||
|
||||
// Add quotes if needed
|
||||
|
@ -485,7 +485,7 @@ func TestAddressFormatting(t *testing.T) {
|
||||
},
|
||||
{ // https://golang.org/issue/12098
|
||||
&Address{Name: "Rob", Address: ""},
|
||||
`"Rob" <>`,
|
||||
`"Rob" <@>`,
|
||||
},
|
||||
{ // https://golang.org/issue/12098
|
||||
&Address{Name: "Rob", Address: "@"},
|
||||
|
Loading…
Reference in New Issue
Block a user