Commit 28a4909c authored by Toon Claes's avatar Toon Claes Committed by Peter Leitzen

Ensure MergeRequestsFinder uses correct Params

Ruby does some weird things when dynamically loading classes. It seems
in some cases it did not load `MergeRequestsFinder::Params` when it's
calling `#params_class`. In that case the superclass method is called
instead.

We discovered this issue in `IssuesFinder` before, and it was addressed
in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/41835.
This change applies the same change to `MergeRequestsFinder`.

Closes https://gitlab.com/gitlab-org/gitlab/-/issues/296939
parent de28bba6
......@@ -57,7 +57,7 @@ class MergeRequestsFinder < IssuableFinder
end
def params_class
MergeRequestsFinder::Params
MergeRequestsFinder.const_get(:Params, false) # rubocop: disable CodeReuse/Finder
end
def filter_items(_items)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment