Fix ActionController::UrlGenerationError
What does this MR do and why?
Sentry: https://sentry.gitlab.net/gitlab/gitlabcom/issues/4084018
Problem
We limit state
value via Route constrains. But we don't validate the
state
parameter if it's provided via query parameters.
Solution
Return 404 page to match the route constrains validation.
Screenshots or screen recordings
Link to test: http://127.0.0.1:3000/gitlab-org/gitlab-test/-/branches?state=test
Before | After |
---|---|
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Vasilii Iakliushin