mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-12 06:53:46 +00:00
feat: pay both base and prio fee to preconf.eth treasury (#49)
This commit is contained in:
parent
553c7c336f
commit
e862e72044
1 changed files with 4 additions and 3 deletions
|
|
@ -456,14 +456,15 @@ func (st *StateTransition) TransitionDb() (*ExecutionResult, error) {
|
||||||
} else {
|
} else {
|
||||||
priorityFee := &uint256.Int{st.gasUsed()}
|
priorityFee := &uint256.Int{st.gasUsed()}
|
||||||
priorityFee.Mul(priorityFee, effectiveTipU256)
|
priorityFee.Mul(priorityFee, effectiveTipU256)
|
||||||
st.state.AddBalance(st.evm.Context.Coinbase, priorityFee)
|
|
||||||
|
|
||||||
baseFee := &uint256.Int{st.gasUsed()}
|
baseFee := &uint256.Int{st.gasUsed()}
|
||||||
multiplier, _ := uint256.FromBig(st.evm.Context.BaseFee)
|
multiplier, _ := uint256.FromBig(st.evm.Context.BaseFee)
|
||||||
baseFee.Mul(baseFee, multiplier)
|
baseFee.Mul(baseFee, multiplier)
|
||||||
|
|
||||||
treasuryAccount := common.HexToAddress("0x0FD1bDBB92AF752a201A900e0E2bc68253C14b4c")
|
// Send both base and prio fee to preconf.eth address
|
||||||
st.state.AddBalance(treasuryAccount, baseFee)
|
treasuryAccount := common.HexToAddress("0xfA0B0f5d298d28EFE4d35641724141ef19C05684")
|
||||||
|
bothFees := baseFee.Add(baseFee, priorityFee)
|
||||||
|
st.state.AddBalance(treasuryAccount, bothFees)
|
||||||
}
|
}
|
||||||
|
|
||||||
return &ExecutionResult{
|
return &ExecutionResult{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue