mirror of
https://github.com/wahyd4/gitlabhq.git
synced 2026-08-09 12:46:07 +10:00
Move application setting to separate variable.
This commit is contained in:
@@ -35,10 +35,12 @@ module Gitlab
|
||||
end
|
||||
|
||||
def non_restricted_level?(level)
|
||||
if current_application_settings.restricted_visibility_levels.nil?
|
||||
restricted_levels = current_application_settings.restricted_visibility_levels
|
||||
|
||||
if restricted_levels.nil?
|
||||
true
|
||||
else
|
||||
! current_application_settings.restricted_visibility_levels.include?(level)
|
||||
!restricted_levels.include?(level)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user