diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2016-08-15 17:57:19 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2016-08-15 17:57:19 +0300 |
commit | 643a368fa437725cbfffcfdc251055c4d125438c (patch) | |
tree | fec1a88b4e81dbe2da97fa86901332668e43bd5a /app/models/merge_request.rb | |
parent | 5e95c0b8d201a6bfdd020aa29a5a6e14c7085e3f (diff) | |
download | gitlab-ce-643a368fa437725cbfffcfdc251055c4d125438c.tar.gz |
Make merge request diff works with new FileCollection logic
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/models/merge_request.rb')
-rw-r--r-- | app/models/merge_request.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb index 7c3845ef538..104f9c7223d 100644 --- a/app/models/merge_request.rb +++ b/app/models/merge_request.rb @@ -172,10 +172,10 @@ class MergeRequest < ActiveRecord::Base end def diffs(diff_options = nil) - if self.compare - self.compare.diffs(diff_options) + if compare + compare.diffs(diff_options) else - Gitlab::Diff::FileCollection::MergeRequest.new(self, diff_options: diff_options) + merge_request_diff.diffs(diff_options) end end |