diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-15 23:53:27 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-15 23:53:27 +0300 |
commit | 601cd5b4c0395abadeda5cfaf3b269b12662f743 (patch) | |
tree | e2e4a53982150ffca0baa7f8f749f1689acc1b71 /app/models/pool_repository.rb | |
parent | 7fc80ce5a5d21d2ba452eefabb02a2c8f7eb86ea (diff) |
Add latest changes from gitlab-org/gitlab@15-0-stable-ee
Diffstat (limited to 'app/models/pool_repository.rb')
-rw-r--r-- | app/models/pool_repository.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/models/pool_repository.rb b/app/models/pool_repository.rb index 78cddaa1302..3461104ae35 100644 --- a/app/models/pool_repository.rb +++ b/app/models/pool_repository.rb @@ -81,7 +81,9 @@ class PoolRepository < ApplicationRecord object_pool.link(repository.raw) end - def mark_obsolete_if_last(repository) + def unlink_repository(repository) + repository.disconnect_alternates + if member_projects.where.not(id: repository.project.id).exists? true else |