fix: env var ADMINS_GROUP_ENABLED optional

This commit is contained in:
seb-by-ouidou 2023-08-30 12:20:20 +00:00 committed by seb-by-ouidou
parent e9c143f226
commit e9f2b56866
3 changed files with 6 additions and 5 deletions

View file

@ -155,6 +155,3 @@ CLAMAV_ENABLED="disabled"
# Siret number used for API Entreprise, by default we use SIRET from dinum
API_ENTREPRISE_DEFAULT_SIRET="put_your_own_siret"
# Admins group usage (gestionnaire de groupes d'administrateurs)
ADMINS_GROUP_ENABLED="disabled"

View file

@ -226,3 +226,7 @@ REDIS_CACHE_SSL_VERIFY_NONE="enabled"
# Setup log level, info if nil
# can be debug, info, warn, error, fatal, and unknown
DS_LOG_LEVEL='info'
# Admins group usage (gestionnaire de groupes d'administrateurs)
# can be removed if needed when EVERY PARTS of the feature will be merged / only used in routes.rb
ADMINS_GROUP_ENABLED="disabled"

View file

@ -56,7 +56,7 @@ Rails.application.routes.draw do
delete 'delete', on: :member
end
if ENV.fetch('ADMINS_GROUP_ENABLED') == 'enabled'
if ENV['ADMINS_GROUP_ENABLED'] == 'enabled' # can be removed if needed when EVERY PARTS of the feature will be merged / from env.example.optional
resources :admins_group_managers, path: 'gestionnaires', only: [:index, :show, :edit, :update]
resources :admins_groups, path: 'groupe_administrateurs', only: [:index, :show, :new, :create, :edit, :update] do
@ -473,7 +473,7 @@ Rails.application.routes.draw do
end
end
if ENV.fetch('ADMINS_GROUP_ENABLED') == 'enabled'
if ENV['ADMINS_GROUP_ENABLED'] == 'enabled' # can be removed if needed when EVERY PARTS of the feature will be merged / from env.example.optional
#
# Admins Group Manager (gestionnaire)