small pixel drawing of a pufferfish clist

Correct invalid list.id references
j3s j3s@c3f.net
Fri, 15 Nov 2019 14:31:28 -0600
commit

56a09a47669aa86fb64d33dd543323441efd9bc4

parent

f37f1e3ecee91bf32914c2b2e25e5e4f9cd4b35e

1 files changed, 4 insertions(+), 4 deletions(-)

jump to
M main.gomain.go

@@ -229,11 +229,11 @@

// Handle a subscribe command func handleSubscribe(msg *email.Email) { listId := strings.TrimPrefix(msg.Subject, "Subscribe ") - listId = strings.TrimPrefix(msg.Subject, "subscribe ") + listId = strings.TrimPrefix(listId, "subscribe ") list := lookupList(listId) if list == nil { - handleInvalidRequest(msg, list.Id) + handleInvalidRequest(msg, listId) os.Exit(0) }

@@ -252,11 +252,11 @@

// Handle an unsubscribe command func handleUnsubscribe(msg *email.Email) { listId := strings.TrimPrefix(msg.Subject, "Unsubscribe ") - listId = strings.TrimPrefix(msg.Subject, "unsubscribe ") + listId = strings.TrimPrefix(listId, "unsubscribe ") list := lookupList(listId) if list == nil { - handleInvalidRequest(msg, list.Id) + handleInvalidRequest(msg, listId) os.Exit(0) }