diff options
author | Micaël Bergeron <mbergeron@gitlab.com> | 2018-02-16 13:49:07 -0500 |
---|---|---|
committer | Micaël Bergeron <mbergeron@gitlab.com> | 2018-02-16 13:51:19 -0500 |
commit | af5cd10e00402937310dfe8e4dfa48b0c15b157a (patch) | |
tree | 34a52733ab36f4b631d626bccc090c23e04d5286 /app | |
parent | f9492554617d807b35358cb799d26e3422dd4c71 (diff) | |
download | gitlab-ce-af5cd10e00402937310dfe8e4dfa48b0c15b157a.tar.gz |
applying feedback32564-fix-double-system-closing-notes
# modified: lib/gitlab/git/commit.rb
Diffstat (limited to 'app')
-rw-r--r-- | app/workers/process_commit_worker.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/workers/process_commit_worker.rb b/app/workers/process_commit_worker.rb index a6330a6c51f..5b25d980bdb 100644 --- a/app/workers/process_commit_worker.rb +++ b/app/workers/process_commit_worker.rb @@ -25,14 +25,14 @@ class ProcessCommitWorker commit = build_commit(project, commit_hash) author = commit.author || user - # this is a GitLab generated commit message, ignore it. - return if commit.merged_merge_request?(user) - process_commit_message(project, commit, user, author, default) update_issue_metrics(commit, author) end def process_commit_message(project, commit, user, author, default = false) + # this is a GitLab generated commit message, ignore it. + return if commit.merged_merge_request?(user) + closed_issues = default ? commit.closes_issues(user) : [] close_issues(project, user, author, commit, closed_issues) if closed_issues.any? |