fix: support multiple pools in stake snapshot query (#396)
This commit is contained in:
parent
43cdb74ee0
commit
4362341b43
4 changed files with 12 additions and 7 deletions
|
|
@ -1,4 +1,7 @@
|
|||
use std::collections::BTreeSet;
|
||||
|
||||
use pallas::{
|
||||
codec::utils::Bytes,
|
||||
ledger::{addresses::Address, traverse::MultiEraBlock},
|
||||
network::{
|
||||
facades::NodeClient,
|
||||
|
|
@ -55,8 +58,8 @@ async fn do_localstate_query(client: &mut NodeClient) {
|
|||
println!("result: {:?}", result);
|
||||
|
||||
// Stake pool ID/verification key hash (either Bech32-decoded or hex-decoded).
|
||||
// Empty Vec means all pools.
|
||||
let pools = vec![];
|
||||
// Empty Set means all pools.
|
||||
let pools: BTreeSet<Bytes> = BTreeSet::new();
|
||||
let result = queries_v16::get_stake_snapshots(client, era, pools)
|
||||
.await
|
||||
.unwrap();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue