diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-08-11 11:28:42 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-08-11 11:28:42 +0300 |
commit | 9f10943c1a76576ac40d96189a28a4d6123a75d8 (patch) | |
tree | 88955d92ebc98a4165d66a36cb8a2cf92709981a /app/services/projects/transfer_service.rb | |
parent | 84727fba96c6794874e1f94d581408b70e1842a7 (diff) |
Revert "Merge branch 'drop-satellites'"
This reverts commit 957e849f41d96fa9778fcdd06792d2f0274b29ab, reversing
changes made to 6b9dbe9f5a175a8162abf296367f561bab3eea1a.
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/services/projects/transfer_service.rb')
-rw-r--r-- | app/services/projects/transfer_service.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/services/projects/transfer_service.rb b/app/services/projects/transfer_service.rb index 550ed6897dd..f43c0ef70e9 100644 --- a/app/services/projects/transfer_service.rb +++ b/app/services/projects/transfer_service.rb @@ -33,6 +33,9 @@ module Projects raise TransferError.new("Project with same path in target namespace already exists") end + # Remove old satellite + project.satellite.destroy + # Apply new namespace id project.namespace = new_namespace project.save! @@ -48,6 +51,9 @@ module Projects # Move wiki repo also if present gitlab_shell.mv_repository("#{old_path}.wiki", "#{new_path}.wiki") + # Create a new satellite (reload project from DB) + Project.find(project.id).ensure_satellite_exists + # clear project cached events project.reset_events_cache |