net/mail: better error in ParseAddress when missing "@domain"
If the input was "John Doe", we're definitely missing "<email>", as "John Doe@domain" isn't a valid email address. However, if the input was "john.doe", it's possible that the user meant "john.doe@domain", and not just "john.doe <email>". Make it clear in the error that either could be the source of the problem. Fixes #27064. Change-Id: I1b8f1342775d711823dffc3db974898ee62d3a34 Reviewed-on: https://go-review.googlesource.com/c/go/+/165517 Run-TryBot: Daniel Martí <mvdan@mvdan.cc> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Showing
Please register or sign in to comment