diff --git a/x/dao/keeper/msg_server_distribution_result.go b/x/dao/keeper/msg_server_distribution_result.go index d82e2ef..0115283 100644 --- a/x/dao/keeper/msg_server_distribution_result.go +++ b/x/dao/keeper/msg_server_distribution_result.go @@ -73,7 +73,13 @@ func (k msgServer) clearUnresolvedClaims(ctx sdk.Context, start int64) (err erro totalAmounts := make(map[string]uint64) for participantAddress := range currentAmounts { - stagedBalance := k.bankKeeper.GetBalance(ctx, sdk.MustAccAddressFromBech32(participantAddress), k.GetParams(ctx).StagedDenom) + // the challenger and challengee can be empty + participantAddressHex, err := sdk.AccAddressFromBech32(participantAddress) + if err != nil { + // try to convert as many claims as possible + continue + } + stagedBalance := k.bankKeeper.GetBalance(ctx, participantAddressHex, k.GetParams(ctx).StagedDenom) totalAmounts[participantAddress] = stagedBalance.Amount.Uint64() } @@ -150,7 +156,8 @@ func (k msgServer) convertOrderedClaim(ctx sdk.Context, claims map[string]uint64 for _, accountAddress := range keys { err = k.convertAccountClaim(ctx, accountAddress, claims[accountAddress]) if err != nil { - return err + // try to convert as many claims as possible + continue } }