mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-10 11:34:59 +00:00
chore: remove vendor-specific references from code comments
This commit is contained in:
committed by
Peter Steinberger
parent
c1f6edf48b
commit
7b58507224
@@ -9,7 +9,7 @@ export { isLoopbackHost };
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns true when the URL uses a WebSocket protocol (ws: or wss:).
|
* Returns true when the URL uses a WebSocket protocol (ws: or wss:).
|
||||||
* Used to distinguish direct-WebSocket CDP endpoints (e.g. Browserbase)
|
* Used to distinguish direct-WebSocket CDP endpoints
|
||||||
* from HTTP(S) endpoints that require /json/version discovery.
|
* from HTTP(S) endpoints that require /json/version discovery.
|
||||||
*/
|
*/
|
||||||
export function isWebSocketUrl(url: string): boolean {
|
export function isWebSocketUrl(url: string): boolean {
|
||||||
|
|||||||
@@ -108,7 +108,7 @@ export async function createTargetViaCdp(opts: {
|
|||||||
|
|
||||||
let wsUrl: string;
|
let wsUrl: string;
|
||||||
if (isWebSocketUrl(opts.cdpUrl)) {
|
if (isWebSocketUrl(opts.cdpUrl)) {
|
||||||
// Direct WebSocket URL (e.g. Browserbase) — skip /json/version discovery.
|
// Direct WebSocket URL — skip /json/version discovery.
|
||||||
wsUrl = opts.cdpUrl;
|
wsUrl = opts.cdpUrl;
|
||||||
} else {
|
} else {
|
||||||
// Standard HTTP(S) CDP endpoint — discover WebSocket URL via /json/version.
|
// Standard HTTP(S) CDP endpoint — discover WebSocket URL via /json/version.
|
||||||
|
|||||||
@@ -98,7 +98,7 @@ export async function isChromeReachable(
|
|||||||
timeoutMs = CHROME_REACHABILITY_TIMEOUT_MS,
|
timeoutMs = CHROME_REACHABILITY_TIMEOUT_MS,
|
||||||
): Promise<boolean> {
|
): Promise<boolean> {
|
||||||
if (isWebSocketUrl(cdpUrl)) {
|
if (isWebSocketUrl(cdpUrl)) {
|
||||||
// Direct WebSocket endpoint (e.g. Browserbase) — probe via WS handshake.
|
// Direct WebSocket endpoint — probe via WS handshake.
|
||||||
return await canOpenWebSocket(cdpUrl, timeoutMs);
|
return await canOpenWebSocket(cdpUrl, timeoutMs);
|
||||||
}
|
}
|
||||||
const version = await fetchChromeVersion(cdpUrl, timeoutMs);
|
const version = await fetchChromeVersion(cdpUrl, timeoutMs);
|
||||||
|
|||||||
Reference in New Issue
Block a user