Skip to content

Commit 2bf8b18

Browse files
committed
bug: use logger from PlaywrightConfig
1 parent 37a6f23 commit 2bf8b18

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/Browser/BrowserContext.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ public function newPage(array $options = []): PageInterface
171171
throw new ProtocolErrorException('No valid pageId returned from transport in newPage', 0);
172172
}
173173

174-
$page = new Page($this->transport, $this, $response['pageId'], $this->config);
174+
$page = new Page($this->transport, $this, $response['pageId'], $this->config, $this->config->logger);
175175
$this->pages[$response['pageId']] = $page;
176176

177177
return $page;

src/Locator/Locator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ public function locator(string $selector): self
272272
$newSelectorChain = clone $this->selectorChain;
273273
$newSelectorChain->append($selector);
274274

275-
return new Locator($this->transport, $this->pageId, $newSelectorChain, $this->frameSelector);
275+
return new Locator($this->transport, $this->pageId, $newSelectorChain, $this->frameSelector, $this->logger);
276276
}
277277

278278
/**

src/Page/Page.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ public function locator(string $selector, array|LocatorOptions $options = []): L
204204
$this->pageId,
205205
$selector,
206206
null,
207-
null,
207+
$this->logger,
208208
$this->normalizeLocatorOptions($options)
209209
);
210210
}

0 commit comments

Comments
 (0)