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

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

module InjectEnterpriseEditionModule
  def prepend_if_ee(constant)
    prepend(constant.constantize) if Gitlab.ee?
  end

  def extend_if_ee(constant)
    extend(constant.constantize) if Gitlab.ee?
  end

  def include_if_ee(constant)
    include(constant.constantize) if Gitlab.ee?
  end
end

Module.prepend(InjectEnterpriseEditionModule)