From a8301e8e1f42a2c836d011cf43cc5b831e139214 Mon Sep 17 00:00:00 2001 From: Alex Skrypnyk Date: Sun, 17 Dec 2023 16:53:58 +1100 Subject: [PATCH] Fixed argument type in switchToIFrame() to be integer. See https://www.w3.org/TR/webdriver/#switch-to-frame --- src/Driver/CoreDriver.php | 4 ++-- src/Driver/DriverInterface.php | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Driver/CoreDriver.php b/src/Driver/CoreDriver.php index a5940ff91..6b509a166 100644 --- a/src/Driver/CoreDriver.php +++ b/src/Driver/CoreDriver.php @@ -160,14 +160,14 @@ public function switchToWindow(?string $name = null) } /** - * @param string|null $name + * @param int|null $name * * @return void * * @throws UnsupportedDriverActionException When operation not supported by the driver * @throws DriverException When the operation cannot be done */ - public function switchToIFrame(?string $name = null) + public function switchToIFrame(?int $name = null) { throw new UnsupportedDriverActionException('iFrames management is not supported by %s', $this); } diff --git a/src/Driver/DriverInterface.php b/src/Driver/DriverInterface.php index a8a96b3f9..b5e397b1b 100644 --- a/src/Driver/DriverInterface.php +++ b/src/Driver/DriverInterface.php @@ -184,14 +184,14 @@ public function switchToWindow(?string $name = null); /** * Switches to specific iFrame. * - * @param string|null $name iframe name (null for switching back) + * @param int|null $name iframe name (null for switching back) * * @return void * * @throws UnsupportedDriverActionException When operation not supported by the driver * @throws DriverException When the operation cannot be done */ - public function switchToIFrame(?string $name = null); + public function switchToIFrame(?int $name = null); /** * Sets specific request header on client.