Replace content_security_policy_nonce with content_security_policy_script_nonce.

To avoid an conflict with Rails, and to avoid confusing by twitter's gem overloading the method.
This commit is contained in:
Dennis Schubert 2020-02-09 18:02:06 +01:00 committed by Benjamin Neff
parent 25e9728fae
commit 75ef13b5d1
No known key found for this signature in database
GPG key ID: 971464C3F1A90194
2 changed files with 2 additions and 2 deletions

View file

@ -2,7 +2,7 @@
-# licensed under the Affero General Public License version 3 or later. See -# licensed under the Affero General Public License version 3 or later. See
-# the COPYRIGHT file. -# the COPYRIGHT file.
%script{nonce: content_security_policy_nonce(:script)} %script{nonce: content_security_policy_script_nonce}
:plain :plain
$(document).ready(function () { $(document).ready(function () {
var data = $.parseJSON( "#{escape_javascript(@contacts_json).html_safe}" ), var data = $.parseJSON( "#{escape_javascript(@contacts_json).html_safe}" ),

View file

@ -21,7 +21,7 @@
= stylesheet_link_tag :poltergeist_disable_transition, media: "all" = stylesheet_link_tag :poltergeist_disable_transition, media: "all"
= jquery_include_tag = jquery_include_tag
= include_gon(camel_case: true, nonce: content_security_policy_nonce(:script)) = include_gon(camel_case: true, nonce: content_security_policy_script_nonce)
= yield(:javascript) = yield(:javascript)
= csrf_meta_tag = csrf_meta_tag