Web Inspector: Fix double remove of ResourceCollection if type changes
https://bugs.webkit.org/show_bug.cgi?id=164268
Patch by Devin Rousso <dcrousso+webkit@gmail.com> on 2016-11-01
Reviewed by Joseph Pecoraro.
Source/WebInspectorUI:
* UserInterface/Models/ResourceCollection.js:
(WebInspector.ResourceCollection.prototype._resourceTypeDidChange):
Change logic so that a non-typed collection will not try to remove a resource that has
changed types from the sub-collection of its old type, since the sub-collection itself will
handle the removal inside its own event listener for the type change.
LayoutTests:
* inspector/unit-tests/resource-collection-expected.txt:
Fixed test to not expect a double remove.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@208234 268f45cc-cd09-0410-ab3c-d52691b4dbfc
4 files changed