diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-10 09:17:41 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-10 09:17:41 +0300 |
commit | b4ea95860f6fa2621539940db6d3b4363f2c639b (patch) | |
tree | 6eaae2c497d2a4fd0008da48bb2a4c04c2de5e75 /app/models/namespace_statistics.rb | |
parent | 8e6b1dc7f7dfb9a7f8431f7c246415e34d31870a (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/namespace_statistics.rb')
-rw-r--r-- | app/models/namespace_statistics.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/namespace_statistics.rb b/app/models/namespace_statistics.rb index 9a6244dbde8..04ca05d85ff 100644 --- a/app/models/namespace_statistics.rb +++ b/app/models/namespace_statistics.rb @@ -29,6 +29,10 @@ class NamespaceStatistics < ApplicationRecord # rubocop:disable Gitlab/Namespace end def update_storage_size + # This prevents failures with older database schemas, such as those + # in migration specs. + return unless self.class.database.cached_column_exists?(:dependency_proxy_size) + self.storage_size = dependency_proxy_size end |