Commit d41fc61f authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Refactor compared_diff_version method in merge requests controller

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 6f7a3ee6
......@@ -542,12 +542,8 @@ class Projects::MergeRequestsController < Projects::ApplicationController
end
def compared_diff_version
compare = @merge_request_diff.compare_with(@start_sha)
if compare
@diffs = compare.diffs(diff_options)
@diff_notes_disabled = true
end
@diffs = @merge_request_diff.compare_with(@start_sha).diffs(diff_options)
end
def original_diff_version
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment