From 12d6b9c4ea26b26d0428df2d05c3078464068392 Mon Sep 17 00:00:00 2001 From: Alex Potsides Date: Tue, 18 Apr 2023 20:02:25 +0200 Subject: [PATCH] fix: specify protocol stream sink return type (#60) To be specific with tsc and avoid the `unknown` type. --- src/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/index.ts b/src/index.ts index 3431c073fd..ed3e394fc4 100644 --- a/src/index.ts +++ b/src/index.ts @@ -4,8 +4,8 @@ import type { AbortOptions } from '@libp2p/interfaces' export { PROTOCOL_ID } -export interface ProtocolStream { - stream: Duplex, Source> +export interface ProtocolStream> { + stream: Duplex, Source, RSink> protocol: string }