BigW Consortium Gitlab

Change project lookup order for api

parent 25f68a71
......@@ -47,7 +47,7 @@ module API
end
def find_project(id)
project = Project.find_by(id: id) || Project.find_with_namespace(id)
project = Project.find_with_namespace(id) || Project.find_by(id: id)
if project && can?(current_user, :read_project, project)
project
......
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