From 3c55168b72c022b618822c7993b7692f583506db Mon Sep 17 00:00:00 2001 From: hozan23 Date: Sun, 30 Jun 2024 20:03:02 +0200 Subject: jsonrpc: remove redundant macro codes in the main crate and clean up internal proc macros --- jsonrpc/src/server/channel.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'jsonrpc/src/server/channel.rs') diff --git a/jsonrpc/src/server/channel.rs b/jsonrpc/src/server/channel.rs index 36896b4..7eff66f 100644 --- a/jsonrpc/src/server/channel.rs +++ b/jsonrpc/src/server/channel.rs @@ -52,7 +52,7 @@ impl Subscription { } /// Checks from the partent if this subscription is still subscribed - pub async fn still_subscribed(&self) -> bool { + async fn still_subscribed(&self) -> bool { match self.parent.upgrade() { Some(parent) => parent.subs.lock().await.contains(&self.id), None => false, @@ -93,7 +93,8 @@ impl Channel { subs.remove(i); } - pub fn close(&self) { + /// Closes the [`Channel`] + pub(crate) fn close(&self) { self.chan.close(); } } -- cgit v1.2.3