Fix routing issues when navigating over tree, commits etc
This commit is contained in:
parent
49e73f8ac1
commit
c8ba5c2d58
7 changed files with 44 additions and 5 deletions
|
@ -102,7 +102,7 @@ class Project < ActiveRecord::Base
|
|||
if id.include?("/")
|
||||
id = id.split("/")
|
||||
namespace_id = Namespace.find_by_path(id.first).id
|
||||
where(namespace_id: namespace_id).find_by_path(id.last)
|
||||
where(namespace_id: namespace_id).find_by_path(id.second)
|
||||
else
|
||||
where(path: id, namespace_id: nil).last
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue