From: Anton Khorev Date: Tue, 15 Aug 2023 15:40:49 +0000 (+0300) Subject: Disallow changesets query with both time and order=oldest X-Git-Tag: live~1131^2~2 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/7bca06a3d31602f896431269a3dc493aa819b70a Disallow changesets query with both time and order=oldest --- diff --git a/app/controllers/api/changesets_controller.rb b/app/controllers/api/changesets_controller.rb index 8a1b9f55b..2f397b706 100644 --- a/app/controllers/api/changesets_controller.rb +++ b/app/controllers/api/changesets_controller.rb @@ -157,6 +157,8 @@ module Api ## # query changesets by bounding box, time, user or open/closed status. def query + raise OSM::APIBadUserInput, "cannot use order=oldest with time" if params[:time] && params[:order] == "oldest" + # find any bounding box bbox = BoundingBox.from_bbox_params(params) if params["bbox"]