Title: [282477] trunk/Source/WebInspectorUI
- Revision
- 282477
- Author
- [email protected]
- Date
- 2021-09-15 15:12:01 -0700 (Wed, 15 Sep 2021)
Log Message
Web Inspector: `TreeOutline` should return early when failing to find an ancestor while populating the tree
https://bugs.webkit.org/show_bug.cgi?id=230287
Reviewed by Devin Rousso.
When an ancestor can not be found, we should return to prevent additional work (which will fail) from being done.
* UserInterface/Views/TreeOutline.js:
(WI.TreeOutline.prototype.findTreeElement):
Modified Paths
Diff
Modified: trunk/Source/WebInspectorUI/ChangeLog (282476 => 282477)
--- trunk/Source/WebInspectorUI/ChangeLog 2021-09-15 21:51:06 UTC (rev 282476)
+++ trunk/Source/WebInspectorUI/ChangeLog 2021-09-15 22:12:01 UTC (rev 282477)
@@ -1,5 +1,17 @@
2021-09-15 Patrick Angle <[email protected]>
+ Web Inspector: `TreeOutline` should return early when failing to find an ancestor while populating the tree
+ https://bugs.webkit.org/show_bug.cgi?id=230287
+
+ Reviewed by Devin Rousso.
+
+ When an ancestor can not be found, we should return to prevent additional work (which will fail) from being done.
+
+ * UserInterface/Views/TreeOutline.js:
+ (WI.TreeOutline.prototype.findTreeElement):
+
+2021-09-15 Patrick Angle <[email protected]>
+
Web Inspector: `DOMTreeUpdater` doesn't complete deferred updating/clear updated lists when a node isn't found in the tree
https://bugs.webkit.org/show_bug.cgi?id=230289
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (282476 => 282477)
--- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2021-09-15 21:51:06 UTC (rev 282476)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2021-09-15 22:12:01 UTC (rev 282477)
@@ -516,8 +516,10 @@
// FIXME: we could do something faster than findTreeElement since we will know the next
// ancestor exists in the tree.
item = this.findTreeElement(ancestors[i], isAncestor, getParent);
- if (item)
- item.onpopulate();
+ if (!item)
+ return null;
+
+ item.onpopulate();
}
return this.getCachedTreeElement(representedObject);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes