Index: tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate |
diff --git a/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate b/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate |
index 1ba903c8d3615d54d823262a92587b929ed2c29f..4a7c784bed3d6981bfc53d863aa0e3a813cdc28a 100644 |
--- a/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate |
+++ b/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate |
@@ -152,7 +152,7 @@ $!MEMBERS |
} |
if (!isNative) { |
- var doc = _getTemplateContentsOwner(templateElement.document); |
+ var doc = _getTemplateContentsOwner(templateElement.ownerDocument); |
templateElement._templateContent = doc.createDocumentFragment(); |
} |
@@ -201,7 +201,7 @@ $!MEMBERS |
// + <td>Bar</td> |
// |
static Element _extractTemplateFromAttributeTemplate(Element el) { |
- var template = el.document.createElement('template'); |
+ var template = el.ownerDocument.createElement('template'); |
el.parentNode.insertBefore(template, el); |
for (var name in el.attributes.keys.toList()) { |