Skip to content

Commit

Permalink
chore: address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Lightning00Blade committed Oct 17, 2024
1 parent 7c03e2c commit f41dba9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/bidiMapper/modules/cdp/CdpTarget.ts
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,12 @@ export class CdpTarget {
blockedRequest.map((request) => request.waitNextPhase)
)
.then(async () => {
const blockedRequest = this.#networkStorage
.getRequestsByTarget(this)
.filter((request) => request.interceptPhase);
if (blockedRequest.length) {
return await this.toggleFetchIfNeeded();
}
return await this.#cdpClient.sendCommand('Fetch.disable');
})
.catch((error) => {
Expand Down
2 changes: 1 addition & 1 deletion src/bidiMapper/modules/network/NetworkRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,7 @@ export class NetworkRequest {
}

dispose() {
this.waitNextPhase.reject(new Error());
this.waitNextPhase.reject(new Error('waitNextPhase disposed'));
}

async #continueWithAuth(
Expand Down

0 comments on commit f41dba9

Please sign in to comment.