~sircmpwn/aerc

worker/lib/parse: be more tolerant with parsing email addresses v3 PROPOSED

Timmy Douglas
Timmy Douglas: 1
 worker/lib/parse: be more tolerant with parsing email addresses

 1 files changed, 1 insertions(+), 1 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~sircmpwn/aerc/patches/9700/mbox | git am -3
Learn more about email & git

[PATCH v3] worker/lib/parse: be more tolerant with parsing email addresses Export this patch

Timmy Douglas
---
 worker/lib/parse.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/worker/lib/parse.go b/worker/lib/parse.go
index 288dade..fd744a7 100644
--- a/worker/lib/parse.go
+++ b/worker/lib/parse.go
@@ -145,7 +145,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.Contains(hdr, "@") {
		if hdr, err := h.Text(key); err == nil {
			return []*models.Address{&models.Address{
				Name: hdr,
			}}, nil
-- 
2.20.1
Thanks!

To git.sr.ht:~sircmpwn/aerc
   77d54fe..8c8096d  master -> master
View this thread in the archives