Commit af2e66a5 authored by Heimdall's avatar Heimdall
Browse files

fix lint error

parent f088fc9e
Pipeline #265161001 passed with stages
in 28 minutes and 50 seconds
......@@ -265,9 +265,11 @@ func (h ErrataTxHandler) processErrataOutboundTx(ctx cosmos.Context, msg MsgErra
runeValue := p.AssetValueInRune(coin.Amount)
p.BalanceRune = p.BalanceRune.Add(runeValue)
p.BalanceAsset = common.SafeSub(p.BalanceAsset, coin.Amount)
h.keeper.SendFromModuleToModule(ctx, ReserveName, AsgardName, common.Coins{
if err := h.keeper.SendFromModuleToModule(ctx, ReserveName, AsgardName, common.Coins{
common.NewCoin(common.RuneAsset(), runeValue),
}); err != nil {
return nil, fmt.Errorf("fail to send fund from reserve to asgard: %w", err)
if err := h.keeper.SetPool(ctx, p); err != nil {
return nil, fmt.Errorf("fail to save pool (%s) : %w", p.Asset, err)
......@@ -108,6 +108,7 @@ func setupKeeperForTest(c *C) (cosmos.Context, keeper.Keeper) {
k := keeper.NewKeeper(marshaler, bk, ak, keyThorchain)
FundModule(c, ctx, k, ModuleName, 1000000*common.One)
FundModule(c, ctx, k, AsgardName, common.One)
FundModule(c, ctx, k, ReserveName, 10000*common.One)
k.SaveNetworkFee(ctx, common.BNBChain, NetworkFee{
Chain: common.BNBChain,
TransactionSize: 1,
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment