diff options
author | Constance Okoghenun <constanceokoghenun@gmail.com> | 2018-11-05 10:33:05 +0100 |
---|---|---|
committer | Constance Okoghenun <constanceokoghenun@gmail.com> | 2018-11-05 10:33:05 +0100 |
commit | 3bac1a322c82dd9b6e9b23edd66fa45afaa9859f (patch) | |
tree | d3e7d47a3e0c8047cb2972aefbc12fe1e3080ef8 /app/models/lfs_object.rb | |
parent | fe7b6f57120946a5d5fe4a4d54a245dc76b06dc8 (diff) | |
parent | 9e2eb85e365e2a33e52e3f1f48cc23ad4201a52b (diff) | |
download | gitlab-ce-issue_51323.tar.gz |
Merge branch 'master' of https://gitlab.com/gitlab-org/gitlab-ce into issue_51323issue_51323
Diffstat (limited to 'app/models/lfs_object.rb')
-rw-r--r-- | app/models/lfs_object.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/lfs_object.rb b/app/models/lfs_object.rb index 97bf5d611c2..69c563545bb 100644 --- a/app/models/lfs_object.rb +++ b/app/models/lfs_object.rb @@ -7,7 +7,7 @@ class LfsObject < ActiveRecord::Base has_many :lfs_objects_projects, dependent: :destroy # rubocop:disable Cop/ActiveRecordDependent has_many :projects, through: :lfs_objects_projects - scope :with_files_stored_locally, -> { where(file_store: [nil, LfsObjectUploader::Store::LOCAL]) } + scope :with_files_stored_locally, -> { where(file_store: LfsObjectUploader::Store::LOCAL) } validates :oid, presence: true, uniqueness: true @@ -26,7 +26,7 @@ class LfsObject < ActiveRecord::Base end def local_store? - [nil, LfsObjectUploader::Store::LOCAL].include?(self.file_store) + file_store == LfsObjectUploader::Store::LOCAL end # rubocop: disable DestroyAll |