Aug 27 - Add MySQL optimize and security check
This commit is contained in:
@@ -103,8 +103,8 @@ def list_scheduled():
|
||||
if user.role not in _ALLOWED_ROLES:
|
||||
return api_error('Access denied', 403)
|
||||
|
||||
limit = min(int(request.args.get('limit', 100)), 200)
|
||||
offset = max(int(request.args.get('offset', 0)), 0)
|
||||
limit = min(request.args.get('limit', 100, type=int) or 100, 200)
|
||||
offset = max(request.args.get('offset', 0, type=int) or 0, 0)
|
||||
|
||||
query = ScheduledInspection.query.filter(ScheduledInspection.active.is_(True))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user