Commit ceff8106 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Create merge request diff on merge request creation

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 2afcc9e9
...@@ -286,6 +286,10 @@ class MergeRequest < ActiveRecord::Base ...@@ -286,6 +286,10 @@ class MergeRequest < ActiveRecord::Base
end end
end end
def create_merge_request_diff
merge_request_diffs.create
end
def update_merge_request_diff def update_merge_request_diff
if source_branch_changed? || target_branch_changed? if source_branch_changed? || target_branch_changed?
reload_diff reload_diff
......
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