Do not rely on rails env to detect staging
This commit is contained in:
parent
ebc7044743
commit
f4f3a302b9
3 changed files with 6 additions and 2 deletions
|
@ -50,6 +50,10 @@ module ApplicationHelper
|
|||
current_administrateur&.email
|
||||
end
|
||||
|
||||
def staging?
|
||||
ENV['APP_NAME'] == 'tps_dev'
|
||||
end
|
||||
|
||||
def root_path_for_profile(nav_bar_profile)
|
||||
case nav_bar_profile
|
||||
when :gestionnaire
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
%body
|
||||
= render partial: 'layouts/support_navigator_banner'
|
||||
= render partial: 'layouts/pre_maintenance'
|
||||
- if Rails.env == 'staging'
|
||||
- if staging?
|
||||
#beta
|
||||
Env Test
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
.page-wrapper
|
||||
= render partial: "layouts/support_navigator_banner"
|
||||
= render partial: 'layouts/pre_maintenance'
|
||||
- if Rails.env == "staging"
|
||||
- if staging?
|
||||
#beta
|
||||
Env Test
|
||||
|
||||
|
|
Loading…
Reference in a new issue