mirror of
https://github.com/jhillyerd/inbucket.git
synced 2026-01-09 04:31:55 +00:00
Accept and handle emails sent with an empty 821.From / return-path as… (#561)
* Accept and handle emails sent with an empty 821.From / return-path as it would any other email.
This commit is contained in:
@@ -75,6 +75,11 @@ func (a *Addressing) NewRecipient(address string) (*Recipient, error) {
|
||||
// ParseOrigin parses an address into a Origin. This is used for parsing MAIL FROM argument,
|
||||
// not To headers.
|
||||
func (a *Addressing) ParseOrigin(address string) (*Origin, error) {
|
||||
if address == "" {
|
||||
return &Origin{
|
||||
addrPolicy: a,
|
||||
}, nil
|
||||
}
|
||||
local, domain, err := ParseEmailAddress(address)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
||||
Reference in New Issue
Block a user