mirror of
https://github.com/writeas/writefreely
synced 2025-02-02 20:17:18 +01:00
Send correct status on 404 in handleHTTPError
This commit is contained in:
parent
8a07c0f0a0
commit
19215b0355
@ -538,6 +538,7 @@ func (h *Handler) handleHTTPError(w http.ResponseWriter, r *http.Request, err er
|
|||||||
h.errors.Gone.ExecuteTemplate(w, "base", p)
|
h.errors.Gone.ExecuteTemplate(w, "base", p)
|
||||||
return
|
return
|
||||||
} else if err.Status == http.StatusNotFound {
|
} else if err.Status == http.StatusNotFound {
|
||||||
|
w.WriteHeader(err.Status)
|
||||||
h.errors.NotFound.ExecuteTemplate(w, "base", pageForReq(h.app, r))
|
h.errors.NotFound.ExecuteTemplate(w, "base", pageForReq(h.app, r))
|
||||||
return
|
return
|
||||||
} else if err.Status == http.StatusInternalServerError {
|
} else if err.Status == http.StatusInternalServerError {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user