This instance was upgraded to Heptapod 0.27.2 on 2021-12-08 at 22:00 UTC+1

Commit a4b6882f authored by Mario de la Ossa's avatar Mario de la Ossa Committed by Sean McGivern
Browse files

use Gitlab::UserSettings directly as a singleton instead of including/extending it

parent 149231b8a5e8
......@@ -6,7 +6,7 @@
= render 'callout'
.prepend-top-default
- if !current_application_settings.usage_ping_enabled
- if !Gitlab::CurrentSettings.usage_ping_enabled
= render 'disabled'
- elsif @metric.blank?
= render 'no_data'
......
......@@ -119,7 +119,7 @@
.well-segment.admin-well
%h4
Components
- if current_application_settings.version_check_enabled
- if Gitlab::CurrentSettings.version_check_enabled
.pull-right
= version_status_badge
%p
......
......@@ -8,7 +8,7 @@
.pull-left
%p
#{ s_('HealthCheck|Access token is') }
%code#health-check-token= current_application_settings.health_check_access_token
%code#health-check-token= Gitlab::CurrentSettings.health_check_access_token
.prepend-top-10
= button_to _("Reset health check access token"), reset_health_check_token_admin_application_settings_path,
method: :put, class: 'btn btn-default',
......@@ -18,11 +18,11 @@
= link_to s_('More information is available|here'), help_page_path('user/admin_area/monitoring/health_check')
%ul
%li
%code= readiness_url(token: current_application_settings.health_check_access_token)
%code= readiness_url(token: Gitlab::CurrentSettings.health_check_access_token)
%li
%code= liveness_url(token: current_application_settings.health_check_access_token)
%code= liveness_url(token: Gitlab::CurrentSettings.health_check_access_token)
%li
%code= metrics_url(token: current_application_settings.health_check_access_token)
%code= metrics_url(token: Gitlab::CurrentSettings.health_check_access_token)
%hr
.panel.panel-default
......
......@@ -36,7 +36,7 @@
data: { confirm: _("Are you sure you want to reset registration token?") }
= render partial: 'ci/runner/how_to_setup_runner',
locals: { registration_token: current_application_settings.runners_registration_token,
locals: { registration_token: Gitlab::CurrentSettings.runners_registration_token,
type: 'shared' }
.append-bottom-20.clearfix
......
......@@ -4,9 +4,9 @@
%p.lead.append-bottom-20
Please check your email to confirm your account
%hr
- if current_application_settings.after_sign_up_text.present?
- if Gitlab::CurrentSettings.after_sign_up_text.present?
.well-confirmation.text-center
= markdown_field(current_application_settings, :after_sign_up_text)
= markdown_field(Gitlab::CurrentSettings, :after_sign_up_text)
%p.text-center
No confirmation email received? Please check your spam folder or
.append-bottom-20.prepend-top-20.text-center
......
= webpack_bundle_tag 'docs'
%div
- if current_application_settings.help_page_text.present?
= markdown_field(current_application_settings, :help_page_text)
- if Gitlab::CurrentSettings.help_page_text.present?
= markdown_field(Gitlab::CurrentSettings.current_application_settings, :help_page_text)
%hr
%h1
......@@ -14,7 +14,7 @@
= version_status_badge
%hr
- unless current_application_settings.help_page_hide_commercial_content?
- unless Gitlab::CurrentSettings.help_page_hide_commercial_content?
%p.slead
GitLab is open source software to collaborate on code.
%br
......@@ -46,6 +46,6 @@
%li
%button.btn-blank.btn-link.js-trigger-shortcut{ type: 'button' }
Use shortcuts
- unless current_application_settings.help_page_hide_commercial_content?
- unless Gitlab::CurrentSettings.help_page_hide_commercial_content?
%li= link_to 'Get a support subscription', 'https://about.gitlab.com/pricing/'
%li= link_to 'Compare GitLab editions', 'https://about.gitlab.com/features/#compare'
......@@ -3,4 +3,4 @@
= icon('circle', class: 'cgreen')
Integration is active for
= link_to koding_project_url, target: '_blank', rel: 'noopener noreferrer' do
#{current_application_settings.koding_url}
#{Gitlab::CurrentSettings.koding_url}
......@@ -41,7 +41,7 @@
= webpack_bundle_tag "webpack_runtime"
= webpack_bundle_tag "common"
= webpack_bundle_tag "main"
= webpack_bundle_tag "raven" if current_application_settings.clientside_sentry_enabled
= webpack_bundle_tag "raven" if Gitlab::CurrentSettings.clientside_sentry_enabled
= webpack_bundle_tag "test" if Rails.env.test?
- if content_for?(:page_specific_javascripts)
......
......@@ -26,8 +26,8 @@
Perform code reviews and enhance collaboration with merge requests.
Each project can also have an issue tracker and a wiki.
- if current_application_settings.sign_in_text.present?
= markdown_field(current_application_settings, :sign_in_text)
- if Gitlab::CurrentSettings.sign_in_text.present?
= markdown_field(Gitlab::CurrentSettings.current_application_settings, :sign_in_text)
%hr.footer-fixed
.container.footer-container
......
......@@ -28,7 +28,7 @@
= link_to profile_account_path do
%strong.fly-out-top-item-name
#{ _('Account') }
- if current_application_settings.user_oauth_applications?
- if Gitlab::CurrentSettings.user_oauth_applications?
= nav_link(controller: 'oauth/applications') do
= link_to applications_profile_path do
.nav-icon-container
......
......@@ -22,7 +22,7 @@
- else
commented on a #{link_to 'discussion', @target_url}
- elsif current_application_settings.email_author_in_body
- elsif Gitlab::CurrentSettings.email_author_in_body
%p.details
#{link_to @note.author_name, user_url(@note.author)} commented:
......
......@@ -12,7 +12,7 @@
<%= ":" -%>
<% elsif current_application_settings.email_author_in_body -%>
<% elsif Gitlab::CurrentSettings.email_author_in_body -%>
<%= "#{@note.author_name} commented:" -%>
......
- if current_application_settings.email_author_in_body
- if Gitlab::CurrentSettings.email_author_in_body
%p.details
#{link_to @issue.author_name, user_url(@issue.author)} created an issue:
......
- if current_application_settings.email_author_in_body
- if Gitlab::CurrentSettings.email_author_in_body
%p.details
#{link_to @merge_request.author_name, user_url(@merge_request.author)} created a merge request:
......
%p
Hi #{@user['name']}!
%p
- if current_application_settings.allow_signup?
- if Gitlab::CurrentSettings.allow_signup?
Your account has been created successfully.
- else
The Administrator created an account for you. Now you are a member of the company GitLab application.
......
- return unless current_application_settings.project_export_enabled?
- return unless Gitlab::CurrentSettings.project_export_enabled?
- project = local_assigns.fetch(:project)
- expanded = Rails.env.test?
......
......@@ -6,7 +6,7 @@
- link = commit_path(project, commit, merge_request: merge_request)
- cache_key = [project.full_path,
commit.id,
current_application_settings,
Gitlab::CurrentSettings.current_application_settings,
@path.presence,
current_controller?(:commits),
merge_request&.iid,
......
......@@ -31,7 +31,7 @@
.radio
= form.label :enabled_ do
= form.radio_button :enabled, ''
%strong Instance default (#{current_application_settings.auto_devops_enabled? ? 'enabled' : 'disabled'})
%strong Instance default (#{Gitlab::CurrentSettings.auto_devops_enabled? ? 'enabled' : 'disabled'})
%br
%span.descr
Follow the instance default to either have Auto DevOps enabled or disabled when there is no project specific <code>.gitlab-ci.yml</code>.
......
%h3 Shared Runners
.bs-callout.bs-callout-warning.shared-runners-description
- if current_application_settings.shared_runners_text.present?
= markdown_field(current_application_settings, :shared_runners_text)
- if Gitlab::CurrentSettings.shared_runners_text.present?
= markdown_field(Gitlab::CurrentSettings.current_application_settings, :shared_runners_text)
- else
GitLab Shared Runners execute code of different projects on the same Runner
unless you configure GitLab Runner Autoscale with MaxBuilds 1 (which it is
......
class GitGarbageCollectWorker
include ApplicationWorker
include Gitlab::CurrentSettings
sidekiq_options retry: false
......@@ -102,7 +101,7 @@ def flush_ref_caches(project)
end
def bitmaps_enabled?
current_application_settings.housekeeping_bitmaps_enabled
Gitlab::CurrentSettings.housekeeping_bitmaps_enabled
end
def git(write_bitmaps:)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment