summaryrefslogtreecommitdiff
path: root/app/services/groups
diff options
context:
space:
mode:
authorZ.J. van de Weg <git@zjvandeweg.nl>2017-02-20 14:05:44 +0100
committerZ.J. van de Weg <git@zjvandeweg.nl>2017-02-20 14:05:44 +0100
commit2b0e8b86d8aa35ac094d18bfefaa81af916347fa (patch)
treea0469ccf9e179832b2231c7f2abfa23956a4048f /app/services/groups
parent444d71e043eb19979ec1b08504b2760910cb2a47 (diff)
parentc89449e6110c2bdf6e1410bae3e7b7d807c5e305 (diff)
downloadgitlab-ce-2b0e8b86d8aa35ac094d18bfefaa81af916347fa.tar.gz
Merge branch 'master' into zj-create-mattermost-team
Diffstat (limited to 'app/services/groups')
-rw-r--r--app/services/groups/destroy_service.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/services/groups/destroy_service.rb b/app/services/groups/destroy_service.rb
index 7f2d28086f5..2e2d7f884ac 100644
--- a/app/services/groups/destroy_service.rb
+++ b/app/services/groups/destroy_service.rb
@@ -8,7 +8,9 @@ module Groups
end
def execute
- group.projects.each do |project|
+ group.prepare_for_destroy
+
+ group.projects.with_deleted.each do |project|
# Execute the destruction of the models immediately to ensure atomic cleanup.
# Skip repository removal because we remove directory with namespace
# that contain all these repositories