diff --git a/java/src/org/openqa/selenium/manager/SeleniumManager.java b/java/src/org/openqa/selenium/manager/SeleniumManager.java index e2a37fe8e8864..b3608892921de 100644 --- a/java/src/org/openqa/selenium/manager/SeleniumManager.java +++ b/java/src/org/openqa/selenium/manager/SeleniumManager.java @@ -275,7 +275,7 @@ public Result getDriverPath(Capabilities options, boolean offline) { arguments.add("--offline"); } - Proxy proxy = (Proxy) options.getCapability("proxy"); + Proxy proxy = Proxy.extractFrom(options); if (proxy != null) { if (proxy.getSslProxy() != null) { arguments.add("--proxy");