| Index: third_party/WebKit/Source/core/svg/SVGScriptElement.cpp
|
| diff --git a/third_party/WebKit/Source/core/svg/SVGScriptElement.cpp b/third_party/WebKit/Source/core/svg/SVGScriptElement.cpp
|
| index 679b4c016a48f57c6441113d9097341f837c6df1..946c8818bcee8fd16a66af243567b6995c7d23fe 100644
|
| --- a/third_party/WebKit/Source/core/svg/SVGScriptElement.cpp
|
| +++ b/third_party/WebKit/Source/core/svg/SVGScriptElement.cpp
|
| @@ -51,14 +51,6 @@ void SVGScriptElement::ParseAttribute(
|
| EventTypeNames::error,
|
| CreateAttributeEventListener(this, params.name, params.new_value,
|
| EventParameterName()));
|
| - } else if (params.name == HTMLNames::nonceAttr) {
|
| - if (params.new_value == ContentSecurityPolicy::GetNonceReplacementString())
|
| - return;
|
| - setNonce(params.new_value);
|
| - if (RuntimeEnabledFeatures::hideNonceContentAttributeEnabled()) {
|
| - setAttribute(HTMLNames::nonceAttr,
|
| - ContentSecurityPolicy::GetNonceReplacementString());
|
| - }
|
| } else {
|
| SVGElement::ParseAttribute(params);
|
| }
|
| @@ -138,8 +130,9 @@ bool SVGScriptElement::HasChildren() const {
|
| return Node::hasChildren();
|
| }
|
|
|
| -bool SVGScriptElement::IsNonceableElement() const {
|
| - return ContentSecurityPolicy::IsNonceableElement(this);
|
| +const AtomicString& SVGScriptElement::GetNonceForElement() const {
|
| + return ContentSecurityPolicy::IsNonceableElement(this) ? nonce()
|
| + : g_null_atom;
|
| }
|
|
|
| bool SVGScriptElement::AllowInlineScriptForCSP(
|
|
|