summaryrefslogtreecommitdiff
path: root/lib/gitlab/import_export/lfs_restorer.rb
diff options
context:
space:
mode:
authorBob Van Landuyt <bob@vanlanduyt.co>2018-04-04 16:40:58 +0200
committerBob Van Landuyt <bob@vanlanduyt.co>2018-04-05 10:21:51 +0200
commit48b17e991a960c006da278d4c1f534b1db81d070 (patch)
treed4746354205a4695d87143082b560b6b5efac7cb /lib/gitlab/import_export/lfs_restorer.rb
parent10d0f438d823418a4a4f4e4f52e8f35ed10f2a05 (diff)
downloadgitlab-ce-48b17e991a960c006da278d4c1f534b1db81d070.tar.gz
Add helper for accessing lfs_objects for project
This makes accessing LFS Objects for a project easier project.lfs_storage_project.lfs_objects` becomes project.all_lfs_objects This will make the refactor in https://gitlab.com/gitlab-org/gitlab-ce/issues/39769 easier to deal with.
Diffstat (limited to 'lib/gitlab/import_export/lfs_restorer.rb')
-rw-r--r--lib/gitlab/import_export/lfs_restorer.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/import_export/lfs_restorer.rb b/lib/gitlab/import_export/lfs_restorer.rb
index 4f144d5c8e6..b28c3c161b7 100644
--- a/lib/gitlab/import_export/lfs_restorer.rb
+++ b/lib/gitlab/import_export/lfs_restorer.rb
@@ -28,7 +28,7 @@ module Gitlab
lfs_object = LfsObject.find_or_initialize_by(oid: oid, size: size)
lfs_object.file = File.open(path) unless lfs_object.file&.exists?
- @project.lfs_storage_project.lfs_objects << lfs_object
+ @project.all_lfs_objects << lfs_object
end
def lfs_file_paths