diff options
author | Mario de la Ossa <mdelaossa@gitlab.com> | 2018-02-02 21:39:55 +0300 |
---|---|---|
committer | Sean McGivern <sean@mcgivern.me.uk> | 2018-02-02 21:39:55 +0300 |
commit | eaada9d7066a20b5af815f723e09cde60a5c8c10 (patch) | |
tree | 72ba4231e28f1c5e5405db21e0611a55e6428145 /lib/gitlab/protocol_access.rb | |
parent | 8fa2932dc5cc7687e7d85ae7b00c07fd9bcc24a4 (diff) |
use Gitlab::UserSettings directly as a singleton instead of including/extending it
Diffstat (limited to 'lib/gitlab/protocol_access.rb')
-rw-r--r-- | lib/gitlab/protocol_access.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/gitlab/protocol_access.rb b/lib/gitlab/protocol_access.rb index 09fa14764e6..2819c7d062c 100644 --- a/lib/gitlab/protocol_access.rb +++ b/lib/gitlab/protocol_access.rb @@ -1,14 +1,12 @@ module Gitlab module ProtocolAccess - extend Gitlab::CurrentSettings - def self.allowed?(protocol) if protocol == 'web' true - elsif current_application_settings.enabled_git_access_protocol.blank? + elsif Gitlab::CurrentSettings.enabled_git_access_protocol.blank? true else - protocol == current_application_settings.enabled_git_access_protocol + protocol == Gitlab::CurrentSettings.enabled_git_access_protocol end end end |