Skip to content

Commit

Permalink
fix: prevent erroneous new main frame (#10549)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamraine committed Jul 13, 2023
1 parent 43556e9 commit cb46413
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/puppeteer-core/src/common/FrameTree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export class FrameTree<Frame extends BaseFrame> {
this.#childIds.set(frame._parentId, new Set());
}
this.#childIds.get(frame._parentId)!.add(frame._id);
} else {
} else if (!this.#mainFrame) {
this.#mainFrame = frame;
}
this.#waitRequests.get(frame._id)?.forEach(request => {
Expand Down

0 comments on commit cb46413

Please sign in to comment.