diff options
author | StephenButtolph <[email protected]> | 2020-08-20 11:56:38 -0400 |
---|---|---|
committer | StephenButtolph <[email protected]> | 2020-08-20 11:56:38 -0400 |
commit | cb5e141d930e0c245804fe87a2caf4962b8f3c5f (patch) | |
tree | 34662f4c4659a55acf33b554f8720c0b4391b305 /plugin/evm/block.go | |
parent | 6aa9e31ed3082df34373679f98ad2b004bef2ffa (diff) | |
parent | 14fe03cbfecf508848bcd1172ea8d2ee3e41fda4 (diff) |
added fees
Diffstat (limited to 'plugin/evm/block.go')
-rw-r--r-- | plugin/evm/block.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/plugin/evm/block.go b/plugin/evm/block.go index 8e13c67..0779e17 100644 --- a/plugin/evm/block.go +++ b/plugin/evm/block.go @@ -74,6 +74,13 @@ func (b *Block) Parent() snowman.Block { // Verify implements the snowman.Block interface func (b *Block) Verify() error { + // Ensure the minimum gas price is paid for every transaction + for _, tx := range b.ethBlock.Transactions() { + if tx.GasPrice().Cmp(minGasPrice) < 0 { + return errInvalidBlock + } + } + vm := b.vm tx := vm.getAtomicTx(b.ethBlock) if tx != nil { |