Merge branch 'lfs-project-attribute-alias' into 'master'

Alias the lfs_enabled method

Closes #49348

See merge request gitlab-org/gitlab-ce!22501
This commit is contained in:
Nick Thomas 2018-10-23 11:50:31 +00:00
commit d16ef87793
3 changed files with 8 additions and 1 deletions

View file

@ -548,6 +548,8 @@ class Project < ActiveRecord::Base
self[:lfs_enabled] && Gitlab.config.lfs.enabled
end
alias_method :lfs_enabled, :lfs_enabled?
def auto_devops_enabled?
if auto_devops&.enabled.nil?
has_auto_devops_implicitly_enabled?

View file

@ -0,0 +1,5 @@
---
title: Resolve LFS not correctly showing enabled
merge_request: 22501
author:
type: fixed

View file

@ -335,7 +335,7 @@ describe Gitlab::ImportExport::ProjectTreeRestorer do
restored_project_json
expect(project.lfs_enabled).to be_nil
expect(project.lfs_enabled).to be_falsey
end
end