We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c624cc0 commit d2b1c51Copy full SHA for d2b1c51
java/client/src/org/openqa/selenium/support/ui/ExpectedConditions.java
@@ -893,7 +893,9 @@ public String toString() {
893
private static WebElement findElement(By by, WebDriver driver) {
894
try {
895
return driver.findElements(by).stream().findFirst().orElseThrow(
896
- () -> new NoSuchElementException("Cannot locate an element using " + by));
+ () -> new NoSuchElementException("Cannot locate an element using " + by));
897
+ } catch (NoSuchElementException e) {
898
+ throw e;
899
} catch (WebDriverException e) {
900
log.log(Level.WARNING,
901
String.format("WebDriverException thrown by findElement(%s)", by), e);
0 commit comments