summaryrefslogtreecommitdiff
path: root/app/models/project.rb
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-04-04 13:06:11 +0200
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-04-04 13:06:11 +0200
commit666ba382e900b0972d457af4f8784ef61324be5c (patch)
tree7a5984a0e7d27389a98d56ce6cc1b1292281dc78 /app/models/project.rb
parentf60820ed0345513d43a1fd9a8b93caf4d39756f4 (diff)
downloadgitlab-ce-666ba382e900b0972d457af4f8784ef61324be5c.tar.gz
Simplify registry-related code in project model
Diffstat (limited to 'app/models/project.rb')
-rw-r--r--app/models/project.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/app/models/project.rb b/app/models/project.rb
index fa64ccbf7e4..2bbfba90b6b 100644
--- a/app/models/project.rb
+++ b/app/models/project.rb
@@ -1387,10 +1387,6 @@ class Project < ActiveRecord::Base
def has_root_container_repository_tags?
return false unless Gitlab.config.registry.enabled
- ContainerRegistry::Path.new(self.full_path).tap do |path|
- ContainerRepository.build_from_path(path).tap do |repository|
- return repository.has_tags?
- end
- end
+ ContainerRepository.build_root_repository(self).has_tags?
end
end