1
0

Handle NotFound error in Download().

This commit is contained in:
Alexander Andreev 2022-02-07 23:09:18 +04:00
parent d893a9492b
commit d9adf74608
Signed by: Arav
GPG Key ID: 1327FE8A374CC86F

View File

@ -175,7 +175,7 @@ func (h *UploadHandlers) Download(w http.ResponseWriter, r *http.Request) {
stat, err := os.Stat(path) stat, err := os.Stat(path)
if os.IsNotExist(err) { if os.IsNotExist(err) {
w.WriteHeader(http.StatusNotFound) h.NotFound(w, r)
return return
} }