diff options
author | Bob Van Landuyt <bob@gitlab.com> | 2017-03-07 23:49:16 +0100 |
---|---|---|
committer | Bob Van Landuyt <bob@gitlab.com> | 2017-03-13 08:27:51 +0100 |
commit | 224c2addde2cd37daba354cd47a655891387dbe8 (patch) | |
tree | c5cb4542bbf0157c431761b7bcb371fb4b12b30f /app | |
parent | dcec4c531f3268a7ae681bb7cc5d5b7217b4b33a (diff) | |
download | gitlab-ce-224c2addde2cd37daba354cd47a655891387dbe8.tar.gz |
No need to look up the notable separately in the ResolveService
The merge request will now always be there when the discussion was
resolved by creating a new issue.
Diffstat (limited to 'app')
-rw-r--r-- | app/services/discussions/resolve_service.rb | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/app/services/discussions/resolve_service.rb b/app/services/discussions/resolve_service.rb index 4a803b47bba..0437195f588 100644 --- a/app/services/discussions/resolve_service.rb +++ b/app/services/discussions/resolve_service.rb @@ -9,13 +9,7 @@ module Discussions discussion.resolve!(current_user) - notify_discussion_resolved(discussion) - end - - def notify_discussion_resolved(discussion) - noteable = merge_request || discussion.noteable - - MergeRequests::ResolvedDiscussionNotificationService.new(project, current_user).execute(noteable) + MergeRequests::ResolvedDiscussionNotificationService.new(project, current_user).execute(merge_request) SystemNoteService.discussion_continued_in_issue(discussion, project, current_user, follow_up_issue) if follow_up_issue end |