diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-31 18:10:27 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-03-31 18:10:27 +0300 |
commit | 5facc34f44ce8736078127a5df174a7b52d922b4 (patch) | |
tree | b93fbe904139121e82870cc40e5ab240a97b1f08 /app/models/concerns/object_storable.rb | |
parent | ea1dcaef18edf97b3ac73892d64ebaf5eecd7f68 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/concerns/object_storable.rb')
-rw-r--r-- | app/models/concerns/object_storable.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/app/models/concerns/object_storable.rb b/app/models/concerns/object_storable.rb new file mode 100644 index 00000000000..c13dddc0b88 --- /dev/null +++ b/app/models/concerns/object_storable.rb @@ -0,0 +1,10 @@ +# frozen_string_literal: true + +module ObjectStorable + extend ActiveSupport::Concern + + included do + scope :with_files_stored_locally, -> { where(klass::STORE_COLUMN => ObjectStorage::Store::LOCAL) } + scope :with_files_stored_remotely, -> { where(klass::STORE_COLUMN => ObjectStorage::Store::REMOTE) } + end +end |