[openstreetmap/openstreetmap-website] Replace redirect with bad request error for new report with missing params (PR #6125)

Anton Khorev notifications at github.com
Mon Jun 23 12:29:26 UTC 2025


If the user somehow manages to open `/reports/new` page without `reportable_id` and `reportable_type` parameters, send a bad request error instead of redirection.
You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/6125

-- Commit Summary --

  * Replace redirect with bad request error for new report with missing params

-- File Changes --

    M app/controllers/reports_controller.rb (2)
    M config/locales/en.yml (1)
    M test/controllers/reports_controller_test.rb (7)
    M test/system/report_diary_entry_test.rb (6)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/6125.patch
https://github.com/openstreetmap/openstreetmap-website/pull/6125.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6125
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/6125 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250623/f46b3c97/attachment.htm>


More information about the rails-dev mailing list