Skip to content

Commit

Permalink
Update Transform method for latest go-smtp version
Browse files Browse the repository at this point in the history
  • Loading branch information
mback2k committed Mar 4, 2019
1 parent 6ecbef8 commit 06dba21
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -123,14 +123,14 @@ func (bkdvh *backendVHost) signMessage(from string, to []string, r io.Reader, id
}
}

func (bkdvh *backendVHost) Transform(from string, to []string, r io.Reader) (string, []string, io.Reader) {
func (bkdvh *backendVHost) Transform(from string, to []string, r io.Reader) (string, []string, io.Reader, error) {
id := bkdvh.generateMessageID()
log.Printf("Handling message %s from %s to %s", id, from, to)

pr, pw := io.Pipe()
go bkdvh.signMessage(from, to, r, id, pw)

return from, to, pr
return from, to, pr, nil
}

func (bkd *backend) Login(username, password string) (smtp.User, error) {
Expand Down

0 comments on commit 06dba21

Please sign in to comment.