summaryrefslogtreecommitdiff
path: root/app/models/project_statistics.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-09-23 00:12:17 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2021-09-23 00:12:17 +0000
commit5d3bcd82b5d6a8567c3c0b1d1620fdd26a4513c5 (patch)
tree4a8bf39faa97f21de525baa58f17c6b808fa553f /app/models/project_statistics.rb
parent83020ec58ca17261d563b314576b3191e08afba0 (diff)
downloadgitlab-ce-5d3bcd82b5d6a8567c3c0b1d1620fdd26a4513c5.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/project_statistics.rb')
-rw-r--r--app/models/project_statistics.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/project_statistics.rb b/app/models/project_statistics.rb
index 387732cf151..6519cc2699d 100644
--- a/app/models/project_statistics.rb
+++ b/app/models/project_statistics.rb
@@ -70,7 +70,7 @@ class ProjectStatistics < ApplicationRecord
end
def update_lfs_objects_size
- self.lfs_objects_size = project.lfs_objects.sum(:size)
+ self.lfs_objects_size = LfsObject.joins(:lfs_objects_projects).where(lfs_objects_projects: { project_id: project.id }).sum(:size)
end
def update_uploads_size