some api changes

This commit is contained in:
ston1th 2021-10-19 21:24:14 +02:00
commit 70fd3f71e5
11 changed files with 118 additions and 76 deletions

View file

@ -43,7 +43,7 @@ type notFoundHandler struct {
}
func (nf *notFoundHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
types.NewContext(w, r, nf.s.Data, nf.s.log).NotFound()
types.NewContext(w, r, nf.s.Data, nf.s.log).Err(types.ErrInvalidAPIRoute)
}
// NewHTTPServer returns a new HTTPServer