summaryrefslogtreecommitdiff
path: root/lib/api/merge_requests.rb
diff options
context:
space:
mode:
authorFelipe Artur <felipefac@gmail.com>2018-07-30 15:52:42 -0300
committerFelipe Artur <felipefac@gmail.com>2018-08-06 11:58:22 -0300
commitfdb5f285f924e653400f7bbe18d13718c469d74f (patch)
tree3570730544d21c8d463aed792e9adcd686ea436a /lib/api/merge_requests.rb
parentcb2e07309b4e61501a44c3568155bdb73252338f (diff)
downloadgitlab-ce-fdb5f285f924e653400f7bbe18d13718c469d74f.tar.gz
Retrieve merge request closing issues from database cache
Diffstat (limited to 'lib/api/merge_requests.rb')
-rw-r--r--lib/api/merge_requests.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/merge_requests.rb b/lib/api/merge_requests.rb
index 2621c9f8fc2..abad418771c 100644
--- a/lib/api/merge_requests.rb
+++ b/lib/api/merge_requests.rb
@@ -380,7 +380,7 @@ module API
end
get ':id/merge_requests/:merge_request_iid/closes_issues' do
merge_request = find_merge_request_with_access(params[:merge_request_iid])
- issues = ::Kaminari.paginate_array(merge_request.closes_issues(current_user))
+ issues = ::Kaminari.paginate_array(merge_request.visible_closing_issues_for(current_user))
issues = paginate(issues)
external_issues, internal_issues = issues.partition { |issue| issue.is_a?(ExternalIssue) }