FEATURE: Implement nonces for Google Tag Manager integration (#12531)

This commit is contained in:
Penar Musaraj
2021-03-26 11:19:31 -04:00
committed by GitHub
parent d858c7680a
commit 5096920500
7 changed files with 29 additions and 8 deletions

View File

@ -8,14 +8,10 @@ module CommonHelper
end
def render_google_tag_manager_head_code
if Rails.env.production? && SiteSetting.gtm_container_id.present?
render partial: "common/google_tag_manager_head"
end
render partial: "common/google_tag_manager_head" if SiteSetting.gtm_container_id.present?
end
def render_google_tag_manager_body_code
if Rails.env.production? && SiteSetting.gtm_container_id.present?
render partial: "common/google_tag_manager_body"
end
render partial: "common/google_tag_manager_body" if SiteSetting.gtm_container_id.present?
end
end