@tree_edit_project is no longer used

Feedback:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/7237#note_21626434
This commit is contained in:
Lin Jen-Shin 2017-01-26 19:13:02 +08:00
parent 4587c78afa
commit acda0cd48d
1 changed files with 1 additions and 4 deletions

View File

@ -101,7 +101,6 @@ module CreatesCommit
def set_commit_variables
if can?(current_user, :push_code, @project)
# Edit file in this project
@tree_edit_project = @project
@mr_source_project = @project
if @project.forked?
@ -114,10 +113,8 @@ module CreatesCommit
@mr_target_branch = @ref || @target_branch
end
else
# Edit file in fork
@tree_edit_project = current_user.fork_of(@project)
# Merge request from fork to this project
@mr_source_project = @tree_edit_project
@mr_source_project = current_user.fork_of(@project)
@mr_target_project = @project
@mr_target_branch = @ref || @target_branch
end