From 1c8141e021d13f3c0e2e3b08e184b2620db67784 Mon Sep 17 00:00:00 2001 From: Enrico Del Fante Date: Tue, 22 Oct 2024 16:05:08 +0200 Subject: [PATCH] revert visibility changes --- libp2p/src/main/kotlin/io/libp2p/pubsub/AbstractRouter.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libp2p/src/main/kotlin/io/libp2p/pubsub/AbstractRouter.kt b/libp2p/src/main/kotlin/io/libp2p/pubsub/AbstractRouter.kt index aa020b49..d5e16401 100644 --- a/libp2p/src/main/kotlin/io/libp2p/pubsub/AbstractRouter.kt +++ b/libp2p/src/main/kotlin/io/libp2p/pubsub/AbstractRouter.kt @@ -23,7 +23,7 @@ const val DEFAULT_MAX_PUBSUB_MESSAGE_SIZE = 1 shl 20 typealias PubsubMessageHandler = (PubsubMessage) -> CompletableFuture -class DefaultPubsubMessage(override val protobufMessage: Rpc.Message) : AbstractPubsubMessage() { +open class DefaultPubsubMessage(override val protobufMessage: Rpc.Message) : AbstractPubsubMessage() { override val messageId: MessageId = protobufMessage.from.toWBytes() + protobufMessage.seqno.toWBytes() } @@ -104,7 +104,7 @@ abstract class AbstractRouter( } override fun addNewStream(stream: Stream) = addNewStreamWithHandler(stream, null) - private fun addNewStreamWithHandler(stream: Stream, handler: ChannelHandler?) { + protected fun addNewStreamWithHandler(stream: Stream, handler: ChannelHandler?) { initChannelWithHandler(StreamHandler(stream), handler) }