Skip to content

Commit

Permalink
Bug 1819664 - Other drive-by cleanups in L10nMutations. r=smaug
Browse files Browse the repository at this point in the history
  • Loading branch information
emilio committed Mar 3, 2023
1 parent bf64e21 commit 11ccf4b
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions dom/l10n/L10nMutations.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,19 +66,15 @@ void L10nMutations::ContentAppended(nsIContent* aChild) {
return;
}

nsINode* node = aChild;
if (!IsInRoots(node)) {
if (!IsInRoots(aChild)) {
return;
}

ErrorResult rv;
Sequence<OwningNonNull<Element>> elements;
while (node) {
for (nsIContent* node = aChild; node; node = node->GetNextSibling()) {
if (node->IsElement()) {
DOMLocalization::GetTranslatables(*node, elements, rv);
DOMLocalization::GetTranslatables(*node, elements, IgnoreErrors());
}

node = node->GetNextSibling();
}

for (auto& elem : elements) {
Expand Down

0 comments on commit 11ccf4b

Please sign in to comment.