You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The total might be irrelevant depending if we query by withdrawer, validator, or stakeKey. I'd leave it out and stick to just returning a vector of stake entries, with their corresponding keys, amounts and nonces. Calculating the total on the client side—when it makes sense—is trivial.
To support staking in myWitWallet and other libraries, the
queryStakes
JSONRPC method needs to support the following features:queryStakes
should return a map with two keys:total
: The total staked amount.stakes
: An array of stake objects filtered by the specified parameter (withdrawer
,validator
, orstakeKey
).To keep the JSONRPC and the CLI consistent, the changes should also be applied to the CLI method.
Issue related with witnet/my-wit-wallet#618.
The text was updated successfully, but these errors were encountered: