feat(backend): increase per_page cap to 500 in bookings list handler
Raise per_page limit from 100 to 500 in parseGetAllBookingsRequest to support large booking lists. Add test coverage for per_page=500 acceptance and per_page=600 rejection (fallback to 10). Ultraworked with Sisyphus Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
@@ -347,7 +347,7 @@ func parseGetAllBookingsRequest(r *http.Request) GetAllBookingsRequest {
|
||||
}
|
||||
}
|
||||
if perPageStr := r.URL.Query().Get("per_page"); perPageStr != "" {
|
||||
if perPage, err := strconv.Atoi(perPageStr); err == nil && perPage > 0 && perPage <= 100 {
|
||||
if perPage, err := strconv.Atoi(perPageStr); err == nil && perPage > 0 && perPage <= 500 {
|
||||
req.PerPage = perPage
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user