diff options
author | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2016-07-06 00:36:23 -0300 |
---|---|---|
committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2016-07-06 13:08:12 -0300 |
commit | 4e5de3e6ee822c63e7d2278ef8449275ca1fc9f1 (patch) | |
tree | 8fd67d7b3df7de8c9a7243d35ec1debaae0c09ca | |
parent | 22780c4ac32a29347317a979c4b8bdf2913d34f7 (diff) | |
download | gitlab-ce-4e5de3e6ee822c63e7d2278ef8449275ca1fc9f1.tar.gz |
Doesn't trigger Git hooks when cleaning up restored branches from GitHub
-rw-r--r-- | lib/gitlab/github_import/importer.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/gitlab/github_import/importer.rb b/lib/gitlab/github_import/importer.rb index 730978d502b..3932fcb1eda 100644 --- a/lib/gitlab/github_import/importer.rb +++ b/lib/gitlab/github_import/importer.rb @@ -131,8 +131,10 @@ module Gitlab def clean_up_restored_branches(branches) branches.each do |name, _| client.delete_ref(repo, "heads/#{name}") - project.repository.rm_branch(project.creator, name) + project.repository.delete_branch(name) rescue Rugged::ReferenceError end + + project.repository.after_remove_branch end def apply_labels(issuable) |