Index: pkg/mdv/lib/src/template_iterator.dart |
diff --git a/pkg/mdv/lib/src/template_iterator.dart b/pkg/mdv/lib/src/template_iterator.dart |
index 84581657b87902afc5084e1aa70de93e8540357e..ce564ad0dc4c8727fae51503fb89ae0e4b8ae962 100644 |
--- a/pkg/mdv/lib/src/template_iterator.dart |
+++ b/pkg/mdv/lib/src/template_iterator.dart |
@@ -336,7 +336,7 @@ class _TemplateIterator { |
var template = _templateElement; |
var delegate = template.bindingDelegate; |
- if (template.parentNode == null || template.document.window == null) { |
+ if (template.parentNode == null || template.ownerDocument.window == null) { |
close(); |
// TODO(jmesserly): MDV calls templateIteratorTable.delete(this) here, |
// but I think that's a no-op because only nodes are used as keys. |