Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(693)

Unified Diff: Source/core/dom/Document.cpp

Issue 727283002: Custom Elements in template should not be upgraded (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Using ensureTemplateDocument() Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/dom/HTMLTemplateElement/import-template-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Document.cpp
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp
index f8b010f16f056201ec128efaef0792b3e61e6405..aa20b9ffb261ff1a34032d9568704e323b5e4513 100644
--- a/Source/core/dom/Document.cpp
+++ b/Source/core/dom/Document.cpp
@@ -993,7 +993,9 @@ PassRefPtrWillBeRawPtr<Node> Document::importNode(Node* importedNode, bool deep,
if (!importContainerNodeChildren(oldElement, newElement, exceptionState))
return nullptr;
if (isHTMLTemplateElement(*oldElement)
- && !importContainerNodeChildren(toHTMLTemplateElement(oldElement)->content(), toHTMLTemplateElement(newElement)->content(), exceptionState))
+ && !ensureTemplateDocument().importContainerNodeChildren(
+ toHTMLTemplateElement(oldElement)->content(),
+ toHTMLTemplateElement(newElement)->content(), exceptionState))
return nullptr;
}
« no previous file with comments | « LayoutTests/fast/dom/HTMLTemplateElement/import-template-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698