Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Unexpected return for QueryDistributionRewards #73

Open
shifty11 opened this issue Jan 19, 2022 · 0 comments
Open

Unexpected return for QueryDistributionRewards #73

shifty11 opened this issue Jan 19, 2022 · 0 comments
Labels
Type: Maintenance updates w/out changing functionality

Comments

@shifty11
Copy link

func (cc *ChainClient) QueryDistributionRewards(ctx context.Context, delegatorAddress sdk.AccAddress, validatorAddress sdk.ValAddress) (sdk.DecCoins, error) {

If I query for rewards and there are none I get a "null". This is unexpected. It would be better to print

[{"denom":"uhuahua","amount":"0"}]

How to reproduce:

lens q distribution rewards chihuahua1tst6rcz4kvckfc4gs8p457gc3pxq7fsn8x75y4 chihuahuavaloper1tst6rcz4kvckfc4gs8p457gc3pxq7fsn537fhf --chain chihuahua
@boojamya boojamya added the Type: Maintenance updates w/out changing functionality label Jan 19, 2022
@boojamya boojamya self-assigned this Jan 19, 2022
@boojamya boojamya removed their assignment Feb 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Type: Maintenance updates w/out changing functionality
Projects
None yet
Development

No branches or pull requests

2 participants