Skip to content

Commit

Permalink
Handle discount in reply
Browse files Browse the repository at this point in the history
  • Loading branch information
pinosu committed Sep 12, 2024
1 parent bcc64d1 commit b4f077a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions x/wasm/keeper/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -648,8 +648,8 @@ func (k Keeper) reply(ctx sdk.Context, contractAddress sdk.AccAddress, reply was
return nil, err
}

// always consider this pinned
replyCosts := k.gasRegister.ReplyCosts(true, reply)
ctx, discount := k.checkDiscountEligibility(ctx, string(codeInfo.CodeHash), k.IsPinnedCode(ctx, contractInfo.CodeID))
replyCosts := k.gasRegister.ReplyCosts(discount, reply)
ctx.GasMeter().ConsumeGas(replyCosts, "Loading CosmWasm module: reply")

env := types.NewEnv(ctx, contractAddress)
Expand Down

0 comments on commit b4f077a

Please sign in to comment.