diff options
author | Adam Pahlevi <adam.pahlevi@gmail.com> | 2017-02-03 06:43:19 +0700 |
---|---|---|
committer | Adam Pahlevi <adam.pahlevi@gmail.com> | 2017-02-03 07:14:04 +0700 |
commit | a0586dbc165cc09422412149712a218938137308 (patch) | |
tree | 1918196171212c48a28bb4e28b6b0fed5f3ad2f2 /lib/gitlab | |
parent | d777e6f1da98be64b872a2bea2222f3e037a3d4d (diff) | |
download | gitlab-ce-a0586dbc165cc09422412149712a218938137308.tar.gz |
replace `find_with_namespace` with `find_by_full_path`
add complete changelog for !8949
Diffstat (limited to 'lib/gitlab')
-rw-r--r-- | lib/gitlab/email/handler/create_issue_handler.rb | 2 | ||||
-rw-r--r-- | lib/gitlab/git_post_receive.rb | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/email/handler/create_issue_handler.rb b/lib/gitlab/email/handler/create_issue_handler.rb index 127fae159d5..b8ec9138c10 100644 --- a/lib/gitlab/email/handler/create_issue_handler.rb +++ b/lib/gitlab/email/handler/create_issue_handler.rb @@ -34,7 +34,7 @@ module Gitlab end def project - @project ||= Project.find_with_namespace(project_path) + @project ||= Project.find_by_full_path(project_path) end private diff --git a/lib/gitlab/git_post_receive.rb b/lib/gitlab/git_post_receive.rb index d32bdd86427..6babea144c7 100644 --- a/lib/gitlab/git_post_receive.rb +++ b/lib/gitlab/git_post_receive.rb @@ -30,11 +30,11 @@ module Gitlab def retrieve_project_and_type @type = :project - @project = Project.find_with_namespace(@repo_path) + @project = Project.find_by_full_path(@repo_path) if @repo_path.end_with?('.wiki') && !@project @type = :wiki - @project = Project.find_with_namespace(@repo_path.gsub(/\.wiki\z/, '')) + @project = Project.find_by_full_path(@repo_path.gsub(/\.wiki\z/, '')) end end |