mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-18 00:17:25 +00:00
15 lines
440 B
Ruby
15 lines
440 B
Ruby
# frozen_string_literal: true
|
|
|
|
module WhiteLabel
|
|
extend ActiveSupport::Concern
|
|
include EnterprisesHelper
|
|
|
|
def hide_ofn_navigation(distributor = current_distributor)
|
|
return false unless OpenFoodNetwork::FeatureToggle.enabled?(:white_label)
|
|
|
|
# if the distributor has the hide_ofn_navigation preference set to true
|
|
# then we should hide the OFN navigation
|
|
@hide_ofn_navigation = distributor.hide_ofn_navigation
|
|
end
|
|
end
|