mirror of
https://github.com/ilri/dspace-statistics-api.git
synced 2025-05-18 02:31:54 +02:00
Make sure limit is between 1 and 100
We were not properly checking whether the limit was greater than 0 in all cases.
This commit is contained in:
@ -108,7 +108,7 @@ def validate_items_post_parameters(req, resp, resource, params):
|
||||
else:
|
||||
raise falcon.HTTPBadRequest(
|
||||
title="Invalid parameter",
|
||||
description='The "limit" parameter is invalid. The value must be an integer between 0 and 100.',
|
||||
description='The "limit" parameter is invalid. The value must be an integer between 1 and 100.',
|
||||
)
|
||||
else:
|
||||
req.context.limit = 100
|
||||
|
Reference in New Issue
Block a user