From b08a8ea890e0d957a8b0b5b28ecc288901e7b182 Mon Sep 17 00:00:00 2001 From: irrun Date: Mon, 1 Apr 2024 15:36:14 +0800 Subject: [PATCH 1/2] fix: NPE --- internal/ethapi/api_bundle.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/ethapi/api_bundle.go b/internal/ethapi/api_bundle.go index 441345f9b6..6dd541338c 100644 --- a/internal/ethapi/api_bundle.go +++ b/internal/ethapi/api_bundle.go @@ -35,7 +35,7 @@ func (s *PrivateTxBundleAPI) BundlePrice(ctx context.Context) *big.Int { // SendBundle will add the signed transaction to the transaction pool. // The sender is responsible for signing the transaction and using the correct nonce and ensuring validity -func (s *PrivateTxBundleAPI) SendBundle(ctx context.Context, args *types.SendBundleArgs) error { +func (s *PrivateTxBundleAPI) SendBundle(ctx context.Context, args types.SendBundleArgs) error { if len(args.Txs) == 0 { return newBundleError(errors.New("bundle missing txs")) } From d1ddc769bea7014a404f34aa781cf44bd0917e95 Mon Sep 17 00:00:00 2001 From: irrun Date: Mon, 1 Apr 2024 22:35:22 +0800 Subject: [PATCH 2/2] fix: bid profit --- miner/bidder.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/miner/bidder.go b/miner/bidder.go index 33cc181e97..e8e3a24dd2 100644 --- a/miner/bidder.go +++ b/miner/bidder.go @@ -216,7 +216,7 @@ func (b *Bidder) bid(work *environment) { BlockNumber: parent.Number.Uint64() + 1, ParentHash: parent.Hash(), GasUsed: work.header.GasUsed, - GasFee: work.profit, + GasFee: work.state.GetBalance(consensus.SystemAddress).ToBig(), Txs: txs, // TODO: decide builderFee according to realtime traffic and validator commission }