[webkit-reviews] review granted: [Bug 190318] Web Inspector: refactor constructor of WI.Resource : [Attachment 351694] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Oct 5 14:13:50 PDT 2018


Joseph Pecoraro <joepeck at webkit.org> has granted Devin Rousso
<drousso at apple.com>'s request for review:
Bug 190318: Web Inspector: refactor constructor of WI.Resource
https://bugs.webkit.org/show_bug.cgi?id=190318

Attachment 351694: Patch

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




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

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

r=me if all tests are green.

> Source/WebInspectorUI/UserInterface/Controllers/NetworkManager.js:139
> +	       let frameResource =
this._addNewResourceToFrameOrTarget(framePayload.url, framePayload.id, {
> +		   loaderIdentifier: framePayload.loaderId,
> +	       }, {
> +		   name: framePayload.name,
> +		   securityOrigin: framePayload.securityOrigin,
> +	       });

Can we style this like:

    let resourceOptions = { ... };
    let frameOptions = { ... };
    let frameResource = this._addNewResourceToFrameOrTarget(...);

> Source/WebInspectorUI/UserInterface/Models/WebSocketResource.js:-28
> -    constructor(url, loaderIdentifier, targetId, requestIdentifier,
requestHeaders, requestData, timestamp, walltime, requestSentTimestamp,
initiatorSourceCodeLocation)

It seems concerning that this takes a subset of Resource initialization options
and so might need to be manually added back if used later.


More information about the webkit-reviews mailing list