This commit is contained in:
parent
030806b0c4
commit
591bd81f28
@ -28,6 +28,7 @@ linters:
|
|||||||
- stylecheck
|
- stylecheck
|
||||||
- exportloopref
|
- exportloopref
|
||||||
- godot
|
- godot
|
||||||
|
|
||||||
linters-settings:
|
linters-settings:
|
||||||
gomnd:
|
gomnd:
|
||||||
ignored-functions:
|
ignored-functions:
|
||||||
|
@ -11,9 +11,9 @@ pipeline:
|
|||||||
event: [push, pull_request, tag, deployment]
|
event: [push, pull_request, tag, deployment]
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
image: golangci/golangci-lint:latest
|
image: golangci/golangci-lint:v1.43.0
|
||||||
commands:
|
commands:
|
||||||
- golangci-lint run -v
|
- golangci-lint run
|
||||||
when:
|
when:
|
||||||
event: [push, pull_request]
|
event: [push, pull_request]
|
||||||
|
|
||||||
|
@ -139,8 +139,7 @@ func (s *HTTPServer) HandlerAPIFileDelete(w http.ResponseWriter, r *http.Request
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
err := s.Files.Delete(id)
|
if err := s.Files.Delete(id); err != nil {
|
||||||
if err != nil {
|
|
||||||
w.WriteHeader(http.StatusBadRequest)
|
w.WriteHeader(http.StatusBadRequest)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user