summaryrefslogtreecommitdiff
path: root/app/models/project.rb
diff options
context:
space:
mode:
authorFrancisco Javier López <fjlopez@gitlab.com>2018-04-06 15:23:49 +0000
committerDouwe Maan <douwe@gitlab.com>2018-04-06 15:23:49 +0000
commitf20912df033d07c46b0989012244d96d0a12b66d (patch)
tree6207b8face17f9b7166ba1a5e047032e3927e53e /app/models/project.rb
parent44f4a674e2a87d104f700265d835aba000c589f0 (diff)
downloadgitlab-ce-f20912df033d07c46b0989012244d96d0a12b66d.tar.gz
Extend API for importing a project export with overwrite support
Diffstat (limited to 'app/models/project.rb')
-rw-r--r--app/models/project.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/models/project.rb b/app/models/project.rb
index 1b29cbf28d2..96907f3b23d 100644
--- a/app/models/project.rb
+++ b/app/models/project.rb
@@ -1472,7 +1472,9 @@ class Project < ActiveRecord::Base
end
def rename_repo_notify!
- send_move_instructions(full_path_was)
+ # When we import a project overwriting the original project, there
+ # is a move operation. In that case we don't want to send the instructions.
+ send_move_instructions(full_path_was) unless started?
expires_full_path_cache
self.old_path_with_namespace = full_path_was