Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-06 21:08:01 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-06 21:08:01 +0300
commit5eb11b697d7ee280b0b5c2ff9a1850a3b5e9b7e3 (patch)
tree78f8dceccd65aec28bb4cb130cac3ff7e3a75c87 /lib/gitlab/github_import
parent506159637da758f448818b834f8482238a9eb4eb (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/github_import')
-rw-r--r--lib/gitlab/github_import/importer/pull_request_importer.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/gitlab/github_import/importer/pull_request_importer.rb b/lib/gitlab/github_import/importer/pull_request_importer.rb
index 6d2aff63a47..f09e0bd9806 100644
--- a/lib/gitlab/github_import/importer/pull_request_importer.rb
+++ b/lib/gitlab/github_import/importer/pull_request_importer.rb
@@ -27,6 +27,7 @@ module Gitlab
mr, already_exists = create_merge_request
if mr
+ set_merge_request_assignees(mr)
insert_git_data(mr, already_exists)
issuable_finder.cache_database_id(mr.id)
end
@@ -57,7 +58,6 @@ module Gitlab
state_id: ::MergeRequest.available_states[pull_request.state],
milestone_id: milestone_finder.id_for(pull_request),
author_id: author_id,
- assignee_id: user_finder.assignee_id_for(pull_request),
created_at: pull_request.created_at,
updated_at: pull_request.updated_at
}
@@ -65,6 +65,10 @@ module Gitlab
create_merge_request_without_hooks(project, attributes, pull_request.iid)
end
+ def set_merge_request_assignees(merge_request)
+ merge_request.assignee_ids = [user_finder.assignee_id_for(pull_request)]
+ end
+
def insert_git_data(merge_request, already_exists)
insert_or_replace_git_data(merge_request, pull_request.source_branch_sha, pull_request.target_branch_sha, already_exists)
# We need to create the branch after the merge request is