From 51253d30d169cec5a67fa735f0cf4f1618ffdedd Mon Sep 17 00:00:00 2001 From: achingbrain Date: Mon, 30 Jun 2025 18:09:51 +0200 Subject: [PATCH] fix: ignore create connection types If we make the implementation match the types then errors start to occur so ignore them for now. --- packages/http/src/http.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/http/src/http.ts b/packages/http/src/http.ts index 5aad930..778fc42 100644 --- a/packages/http/src/http.ts +++ b/packages/http/src/http.ts @@ -67,6 +67,7 @@ class Libp2pAgent extends NodeAgent { this.peer = init.peer } + // @ts-expect-error types are wrong createConnection (options: TcpNetConnectOpts, cb: (err?: Error, socket?: Socket) => void): void { createConnection(this.components.connectionManager, this.peer, options) .then(socket => { @@ -88,6 +89,7 @@ export class HTTP extends HTTPBrowser implements HTTPInterface { return new NodeAgent(options) } + // @ts-expect-error types are wrong return new Libp2pAgent(this.components, { ...options, peer