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
When a secret contract attempts to do the Rewards query from the Distribution module like follows (where delegator is the HumanAddr whose rewards you want to view):
let rewards_resp:RewardsResponse = deps.querier.query(&QueryRequest::Dist(DistQuery::Rewards{
delegator,}))?;
If the delegator does not have any pending rewards, the query returns a null response which causes a parse error. Instead it should always return a valid RewardsResponse, but when there are no rewards, the rewards and total fields should be empty Vecs.
The text was updated successfully, but these errors were encountered:
When a secret contract attempts to do the Rewards query from the Distribution module like follows (where delegator is the HumanAddr whose rewards you want to view):
If the delegator does not have any pending rewards, the query returns a null response which causes a parse error. Instead it should always return a valid
RewardsResponse
, but when there are no rewards, therewards
andtotal
fields should be empty Vecs.The text was updated successfully, but these errors were encountered: