Skip to content
Snippets Groups Projects
Verified Commit 9ea6e27d authored by Spotlight Deveaux's avatar Spotlight Deveaux :fox:
Browse files

Fix defaulting to maxLimits

If the `limits` query parameter is present, we expect it to override the `limit` variable. However, the variable was mistakenly defined locally and fails to override the outer variable.
parent 7604f070
No related branches found
No related tags found
No related merge requests found
......@@ -55,7 +55,7 @@ func ListObjects(w http.ResponseWriter, r *http.Request) {
l = query.Get("limit")
)
if l != "" {
limit, err := strconv.Atoi(l)
limit, err = strconv.Atoi(l)
if err != nil || limit < 0 {
panic(apierrors.InvalidOffsetOrLimit)
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment