[webkit-reviews] review granted: [Bug 192210] Web Inspector: Audit: allow audits to be enabled/disabled : [Attachment 356125] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jan 10 15:34:20 PST 2019


Joseph Pecoraro <joepeck at webkit.org> has granted Devin Rousso
<drousso at apple.com>'s request for review:
Bug 192210: Web Inspector: Audit: allow audits to be enabled/disabled
https://bugs.webkit.org/show_bug.cgi?id=192210

Attachment 356125: Patch

https://bugs.webkit.org/attachment.cgi?id=356125&action=review




--- Comment #4 from Joseph Pecoraro <joepeck at webkit.org> ---
Comment on attachment 356125
  --> https://bugs.webkit.org/attachment.cgi?id=356125
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=356125&action=review

r=me

> Source/WebInspectorUI/UserInterface/Base/ObjectStore.js:55
> +	   if (Array.isArray(WI.ObjectStore._databaseCallbacks)) {

A simple if check be sufficient. Is there a benefit to the extra isArray()
check?

Also this should be covered in the ChangeLog somewhere. Does this reduce
duplicate IndexedDB open() calls?

> Source/WebInspectorUI/UserInterface/Controllers/AuditManager.js:78
> +	       WI.objectStores.audits.clear();
> +	       for (let test of this._tests)
> +		   WI.objectStores.audits.addObject(test);

This feels like it could be put into a well named method. Something like
`_resaveAudits`?


More information about the webkit-reviews mailing list