Archived
1
0
This commit is contained in:
Jeff Becker 2018-01-04 15:23:10 -05:00
parent 92320aff4c
commit 0266deee2b
No known key found for this signature in database
GPG Key ID: F357B3B42F6F9B05

View File

@ -591,16 +591,16 @@ func (self *articleStore) GetMessage(msgid string) (nntp NNTPMessage) {
hdr := textproto.MIMEHeader(msg.Header) hdr := textproto.MIMEHeader(msg.Header)
err = read_message_body(msg.Body, hdr, nil, nil, true, func(n NNTPMessage) { err = read_message_body(msg.Body, hdr, nil, nil, true, func(n NNTPMessage) {
c := chnl c := chnl
// inject pubkey for mod if n != nil {
n.Headers().Set("X-PubKey-Ed25519", hdr.Get("X-PubKey-Ed25519")) // inject pubkey for mod
c <- n n.Headers().Set("X-PubKey-Ed25519", hdr.Get("X-PubKey-Ed25519"))
close(c) c <- n
}
}) })
if err == nil { if err == nil {
nntp = <-chnl nntp = <-chnl
} else { } else {
log.Println("GetMessage() failed to load", msgid, err) log.Println("GetMessage() failed to load", msgid, err)
close(chnl)
} }
} }
} }