|
|
@@ -118,7 +118,7 @@ func handleFailureFn(dsn, failureDir string, ignore *ignorePatterns) func(w http
|
|
|
bs, err := io.ReadAll(lr)
|
|
|
req.Body.Close()
|
|
|
if err != nil {
|
|
|
- http.Error(w, err.Error(), 500)
|
|
|
+ http.Error(w, err.Error(), http.StatusInternalServerError)
|
|
|
return
|
|
|
}
|
|
|
|
|
|
@@ -130,7 +130,7 @@ func handleFailureFn(dsn, failureDir string, ignore *ignorePatterns) func(w http
|
|
|
var reports []ur.FailureReport
|
|
|
err = json.Unmarshal(bs, &reports)
|
|
|
if err != nil {
|
|
|
- http.Error(w, err.Error(), 400)
|
|
|
+ http.Error(w, err.Error(), http.StatusBadRequest)
|
|
|
return
|
|
|
}
|
|
|
if len(reports) == 0 {
|
|
|
@@ -141,7 +141,7 @@ func handleFailureFn(dsn, failureDir string, ignore *ignorePatterns) func(w http
|
|
|
|
|
|
version, err := build.ParseVersion(reports[0].Version)
|
|
|
if err != nil {
|
|
|
- http.Error(w, err.Error(), 400)
|
|
|
+ http.Error(w, err.Error(), http.StatusBadRequest)
|
|
|
return
|
|
|
}
|
|
|
for _, r := range reports {
|