Skip to content

Fix double query string in url

What does this MR do?

This MR should fix the double query string in url that shows up while using the "filter by name .." input on projects list pages and also closes 17743

Steps to reproduce

  • Navigate here https://gitlab.com/explore
  • Navigate to a paginated page using the pagination buttons below, let's say, page 2
  • Use the "filter by name ..." input to search for a project that is listed on the first page let's say "GitLab Community Edition"
  • Notice the url now have double query string character, plus the search returns "no project found". This double query string character, is also true for "filter by name .." input found in paths like this https://gitlab.com/groups/group-string e.g https://gitlab.com/groups/gitlab-org/ but the difference is that search made on paginated page, will actually reset the pagination and return result from the first page just like the way searching issues and merge request works. Digging deep, I discovered that the if condition in this line of code makes that possible. So this MR, should fix these issues, remove the second query string and also when search is made on paginated projects pages as described above, should reset pagination and return results.

What are the relevant issue numbers?

Closes #17743

cc: @jschatz1

Merge request reports