From f92cd4b748d30d527321f89bebda2e076f196723 Mon Sep 17 00:00:00 2001 From: dongsam Date: Fri, 23 Nov 2018 18:40:41 +0900 Subject: [PATCH] remove redundant temporary code remDelPool when calc DelPool --- x/distribution/types/delegator_info.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/x/distribution/types/delegator_info.go b/x/distribution/types/delegator_info.go index 83ca7f8cc95e..decf321298f7 100644 --- a/x/distribution/types/delegator_info.go +++ b/x/distribution/types/delegator_info.go @@ -50,9 +50,8 @@ func (di DelegationDistInfo) WithdrawRewards(wc WithdrawContext, vi ValidatorDis accum := di.GetDelAccum(wc.Height, delegatorShares) di.DelPoolWithdrawalHeight = wc.Height withdrawalTokens := vi.DelPool.MulDec(accum).QuoDec(vi.DelAccum.Accum) - remDelPool := vi.DelPool.Minus(withdrawalTokens) - vi.DelPool = remDelPool + vi.DelPool = vi.DelPool.Minus(withdrawalTokens) vi.DelAccum.Accum = vi.DelAccum.Accum.Sub(accum) return di, vi, fp, withdrawalTokens