mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-10-26 05:35:03 +00:00
Make queryStorage and storagePairs unsafe RPC functions (#7342)
The RPC calls can be rather expensive and can easily bring a RPC node in some problems ;)
This commit is contained in:
1 parent
13be04e0a7
commit
74e8691aa8
4 files changed
+64
-12
No files matched your search
@@ -753,13 +753,18 @@ fn gen_handler<TBl, TBackend, TExPool, TRpc, TCl>(
|
||||
subscriptions.clone(),
|
||||
remote_blockchain.clone(),
|
||||
on_demand,
|
||||
deny_unsafe,
|
||||
);
|
||||
(chain, state, child_state)
|
||||
|
||||
} else {
|
||||
// Full nodes
|
||||
let chain = sc_rpc::chain::new_full(client.clone(), subscriptions.clone());
|
||||
let (state, child_state) = sc_rpc::state::new_full(client.clone(), subscriptions.clone());
|
||||
let (state, child_state) = sc_rpc::state::new_full(
|
||||
client.clone(),
|
||||
subscriptions.clone(),
|
||||
deny_unsafe,
|
||||
);
|
||||
(chain, state, child_state)
|
||||
};
|
||||
|
||||
|
||||
Reference in new issue
Block a user