Skip to content
Snippets Groups Projects
Commit 0a821554 authored by Hugo Trentesaux's avatar Hugo Trentesaux
Browse files

add also smith member count to reveal bug

parent f48e9873
No related branches found
No related tags found
1 merge request!9add smith and membership commands
...@@ -38,6 +38,8 @@ pub enum Subcommand { ...@@ -38,6 +38,8 @@ pub enum Subcommand {
}, },
/// List online authorities /// List online authorities
ShowOnline, ShowOnline,
/// count of smith member
MemberCount,
} }
/// handle smith commands /// handle smith commands
...@@ -78,6 +80,18 @@ pub async fn handle_command(data: Data, command: Subcommand) -> anyhow::Result<( ...@@ -78,6 +80,18 @@ pub async fn handle_command(data: Data, command: Subcommand) -> anyhow::Result<(
data = data.build_client().await?; data = data.build_client().await?;
online(&data).await? online(&data).await?
} }
Subcommand::MemberCount => {
println!(
"smith member count: {:?}",
data.client()
.storage()
.fetch(
&runtime::storage().smith_membership().counter_for_membership(),
None,
)
.await?
)
}
}; };
Ok(()) Ok(())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment