Skip to content

Commit

Permalink
chore: remove redundant checks from network interception (#28922)
Browse files Browse the repository at this point in the history
We only intercept requests in Playwright so these fields are always
undefined.
  • Loading branch information
yury-s authored Jan 9, 2024
1 parent 2ddf3a4 commit 19a4f15
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ export class CRNetworkManager {
});
this._requestIdToRequest.set(requestWillBeSentEvent.requestId, request);

if (requestPausedEvent && !requestPausedEvent.responseStatusCode && !requestPausedEvent.responseErrorReason) {
if (requestPausedEvent) {
// We will not receive extra info when intercepting the request.
// Use the headers from the Fetch.requestPausedPayload and release the allHeaders()
// right away, so that client can call it from the route handler.
Expand Down

0 comments on commit 19a4f15

Please sign in to comment.