aboutsummaryrefslogtreecommitdiff
path: root/worker
diff options
context:
space:
mode:
Diffstat (limited to 'worker')
-rw-r--r--worker/lib/parse.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/worker/lib/parse.go b/worker/lib/parse.go
index 9f9fa62..df9683a 100644
--- a/worker/lib/parse.go
+++ b/worker/lib/parse.go
@@ -173,7 +173,7 @@ func parseAddressList(h *mail.Header, key string) ([]*models.Address, error) {
var converted []*models.Address
addrs, err := h.AddressList(key)
if err != nil {
- if hdr, err := h.Text(key); err != nil && strings.Index(hdr, "@") < 0 {
+ if hdr, err := h.Text(key); err != nil && strings.Contains(hdr, "@") {
return []*models.Address{&models.Address{
Name: hdr,
}}, nil