summaryrefslogtreecommitdiff
path: root/lib/gitlab/github_import/importer.rb
diff options
context:
space:
mode:
authorAhmad Sherif <me@ahmadsherif.com>2016-09-27 19:36:58 +0200
committerAhmad Sherif <me@ahmadsherif.com>2016-09-27 20:45:07 +0200
commitdca1acd6a6eaf78f31e90569ff008b1a26d63fbb (patch)
tree2db692ff39d977b513cb544bbe0c2601861fa66d /lib/gitlab/github_import/importer.rb
parente30bfb809afdbf5596176cf0fe0ea63e976cbb9f (diff)
downloadgitlab-ce-fix/optimize-github-importer-for-speed-and-memory.tar.gz
Call after_remove_branch only once after importing all GitHub PRsfix/optimize-github-importer-for-speed-and-memory
Diffstat (limited to 'lib/gitlab/github_import/importer.rb')
-rw-r--r--lib/gitlab/github_import/importer.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/github_import/importer.rb b/lib/gitlab/github_import/importer.rb
index 1d385dba0f5..b8321244473 100644
--- a/lib/gitlab/github_import/importer.rb
+++ b/lib/gitlab/github_import/importer.rb
@@ -108,6 +108,8 @@ module Gitlab
end
end
end
+
+ project.repository.after_remove_branch
end
def restore_source_branch(pull_request)
@@ -127,8 +129,6 @@ module Gitlab
def clean_up_restored_branches(pull_request)
remove_branch(pull_request.source_branch_name) unless pull_request.source_branch_exists?
remove_branch(pull_request.target_branch_name) unless pull_request.target_branch_exists?
-
- project.repository.after_remove_branch
end
def apply_labels(issuable, raw_issuable)