mirror of
https://github.com/GRFreire/nthmail.git
synced 2026-01-09 12:59:38 +00:00
return 404 not found on email not found, not 500
This commit is contained in:
parent
117766dd64
commit
7999d35a32
@ -197,10 +197,8 @@ func (sr ServerResouces) handleMail(res http.ResponseWriter, req *http.Request)
|
||||
var m db_mail
|
||||
err = row.Scan(&m.Id, &m.Arrived_at, &m.Rcpt_addr, &m.From_addr, &m.Data)
|
||||
if err != nil {
|
||||
res.WriteHeader(500)
|
||||
res.Write([]byte("internal server error"))
|
||||
res.Write([]byte("404 not found"))
|
||||
|
||||
log.Println("could not scan db row")
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user