From dcb3a65a5b60cb0110fa633e60da1a71e6bf17b0 Mon Sep 17 00:00:00 2001 From: Franck Royer Date: Wed, 22 Jun 2022 16:05:32 +1000 Subject: [PATCH] No more tsc error on prod code --- src/lib/waku.ts | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/lib/waku.ts b/src/lib/waku.ts index 1b714700aa..0963e09e0b 100644 --- a/src/lib/waku.ts +++ b/src/lib/waku.ts @@ -1,6 +1,5 @@ import { Noise } from "@chainsafe/libp2p-noise"; import type { PeerId } from "@libp2p/interface-peer-id"; -import { MuxedStream } from "@libp2p/interfaces/stream-muxer/types"; import { Mplex } from "@libp2p/mplex"; import { peerIdFromString } from "@libp2p/peer-id"; import { WebSockets } from "@libp2p/websockets"; @@ -179,13 +178,9 @@ export class Waku { * @param peer The peer to dial * @param protocols Waku protocols we expect from the peer; Default to Relay */ - async dial( - peer: PeerId | Multiaddr, - protocols?: Protocols[] - ): Promise<{ - stream: MuxedStream; - protocol: string; - }> { + // TODO: Any to be removed once libp2p uses @libp2p/interface-connection for + // dialProtocol + async dial(peer: PeerId | Multiaddr, protocols?: Protocols[]): Promise { const _protocols = protocols ?? [Protocols.Relay]; const codecs: string[] = [];