Update core/txpool/validation.go

Co-authored-by: Raneet Debnath <35629432+Raneet10@users.noreply.github.com>
This commit is contained in:
Arpit Temani 2023-12-03 17:14:57 +05:30 committed by GitHub
parent 91ff270cd9
commit 968267957e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -93,7 +93,7 @@ func ValidateTransaction(tx *types.Transaction, blobs []kzg4844.Blob, commits []
return core.ErrTipAboveFeeCap return core.ErrTipAboveFeeCap
} }
// Make sure the transaction is signed properly // Make sure the transaction is signed properly
if _, err := types.Sender(signer, tx); err != nil || !opts.AllowUnprotectedTxs { if _, err := types.Sender(signer, tx); err != nil && !opts.AllowUnprotectedTxs {
return ErrInvalidSender return ErrInvalidSender
} }
// Ensure the transaction has more gas than the bare minimum needed to cover // Ensure the transaction has more gas than the bare minimum needed to cover