Welcome to mirror list, hosted at ThFree Co, Russian Federation.

service_ping_settings.rb « service_ping « services « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 6964210b1db645a8d87680f3934e661f7feb10e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

module ServicePing
  module ServicePingSettings
    extend self

    def product_intelligence_enabled?
      enabled? && !User.single_user&.requires_usage_stats_consent?
    end

    def enabled?
      ::Gitlab::CurrentSettings.usage_ping_enabled?
    end
  end
end

ServicePing::ServicePingSettings.extend_mod_with('ServicePing::ServicePingSettings')