Bug 1221868 - Correct the document check for appending a document fragment node; r=smaug

Differential Revision: https://phabricator.services.mozilla.com/D101339
This commit is contained in:
Edgar Chen 2021-01-11 15:01:09 +00:00
Родитель 736e649a75
Коммит 7330687550
2 изменённых файлов: 1 добавлений и 2 удалений

Просмотреть файл

@ -2523,7 +2523,7 @@ nsINode* nsINode::ReplaceOrInsertBefore(bool aReplace, nsINode* aNewChild,
fragChildren->SetCapacity(count);
for (nsIContent* child = newContent->GetFirstChild(); child;
child = child->GetNextSibling()) {
NS_ASSERTION(child->GetComposedDoc() == nullptr,
NS_ASSERTION(child->GetUncomposedDoc() == nullptr,
"How did we get a child with a current doc?");
fragChildren->AppendElement(child);
}

Просмотреть файл

@ -1,5 +1,4 @@
[adopted-callback.html]
max-asserts: 8
[Moving the <template>'s content of a custom element from the owner document into an HTML document fetched by XHR must enqueue and invoke adoptedCallback]
expected: FAIL