1
0
mirror of https://github.com/muety/wakapi.git synced 2023-08-10 21:12:56 +03:00

fix: crash when calling badge endpoint with no filters applied (resolve #66)

This commit is contained in:
Ferdinand Mütsch
2020-11-01 16:03:30 +01:00
parent 68e66298b8
commit 96ff490d8d
4 changed files with 15 additions and 10 deletions

View File

@ -43,7 +43,7 @@ func (h *AllTimeHandler) ApiGet(w http.ResponseWriter, r *http.Request) {
return
}
vm := v1.NewAllTimeFrom(summary, &models.Filters{Project: values.Get("project")})
vm := v1.NewAllTimeFrom(summary, models.NewFiltersWith(models.SummaryProject, values.Get("project")))
utils.RespondJSON(w, http.StatusOK, vm)
}