diff --git a/core/rawdb/accessors_indexes.go b/core/rawdb/accessors_indexes.go index e769d2e9d1..107448a2e2 100644 --- a/core/rawdb/accessors_indexes.go +++ b/core/rawdb/accessors_indexes.go @@ -176,8 +176,7 @@ func findTxInBlockBody(blockbody rlp.RawValue, target common.Hash) (*types.Trans // HasCanonicalTransaction checks whether a specific transaction is in the database. func HasCanonicalTransaction(db ethdb.Reader, hash common.Hash) bool { - blockNumber := ReadTxLookupEntry(db, hash) - return blockNumber != nil + return ReadTxLookupEntry(db, hash) != nil } // ReadCanonicalTransaction retrieves a specific transaction from the database, along