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 2094ade commit 21570beCopy full SHA for 21570be
src/commonMain/kotlin/org/hildan/chrome/devtools/protocol/ChromeDPClient.kt
@@ -76,6 +76,13 @@ class ChromeDPClient(
76
*/
77
private val httpClient: HttpClient = if (overrideHostHeader) DEFAULT_HTTP_CLIENT_WITH_HOST_OVERRIDE else DEFAULT_HTTP_CLIENT,
78
) {
79
+ init {
80
+ require(remoteDebugUrl.startsWith("http://") || remoteDebugUrl.startsWith("https://")) {
81
+ "This function is meant to be used with 'http://' or 'https://' URLs, but got $remoteDebugUrl. " +
82
+ "If you already have a web socket URL, use ChromeDP.connect(wsUrl) directly instead."
83
+ }
84
85
+
86
/**
87
* Fetches the browser version metadata via the debugger's HTTP API.
88
0 commit comments