Index: third_party/WebKit/Source/core/dom/ModuleScript.h |
diff --git a/third_party/WebKit/Source/core/dom/ModuleScript.h b/third_party/WebKit/Source/core/dom/ModuleScript.h |
index 4b9c5dd7bbabbe7507f4dba944fa2abb331d38d6..22002a40f486ad417cd4815badbe74b47791200e 100644 |
--- a/third_party/WebKit/Source/core/dom/ModuleScript.h |
+++ b/third_party/WebKit/Source/core/dom/ModuleScript.h |
@@ -79,16 +79,19 @@ class CORE_EXPORT ModuleScript final : public Script, public TraceWrapperBase { |
const KURL& base_url, |
const String& nonce, |
ParserDisposition parser_state, |
- WebURLRequest::FetchCredentialsMode credentials_mode) |
+ WebURLRequest::FetchCredentialsMode credentials_mode, |
+ const String& source_text) |
: settings_object_(settings_object), |
record_(record), |
base_url_(base_url), |
instantiation_error_(this), |
nonce_(nonce), |
parser_state_(parser_state), |
- credentials_mode_(credentials_mode) {} |
+ credentials_mode_(credentials_mode), |
+ source_text_(source_text) {} |
- static ModuleScript* CreateInternal(Modulator*, |
+ static ModuleScript* CreateInternal(const String& source_text, |
+ Modulator*, |
ScriptModule, |
const KURL& base_url, |
const String& nonce, |
@@ -142,6 +145,9 @@ class CORE_EXPORT ModuleScript final : public Script, public TraceWrapperBase { |
// https://html.spec.whatwg.org/multipage/webappapis.html#concept-module-script-credentials-mode |
const WebURLRequest::FetchCredentialsMode credentials_mode_; |
+ |
+ // For CSP check. |
+ const String source_text_; |
}; |
} // namespace blink |