mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-18 07:45:30 +00:00
Bug 1591588, remove ComputeIndexOf call and negative index check from within GetWholeText r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D50885 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
ba4d0ad27c
commit
5d8c10a424
@ -89,15 +89,6 @@ void Text::GetWholeText(nsAString& aWholeText, ErrorResult& aRv) {
|
||||
return;
|
||||
}
|
||||
|
||||
int32_t index = parent->ComputeIndexOf(this);
|
||||
NS_WARNING_ASSERTION(index >= 0,
|
||||
"Trying to use .wholeText with an anonymous"
|
||||
"text node child of a binding parent?");
|
||||
if (NS_WARN_IF(index < 0)) {
|
||||
aRv.Throw(NS_ERROR_DOM_NOT_SUPPORTED_ERR);
|
||||
return;
|
||||
}
|
||||
|
||||
Text* first = FirstLogicallyAdjacentTextNode(this);
|
||||
Text* last = LastLogicallyAdjacentTextNode(this);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user