mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 10:22:23 +00:00
fix rawdb isNotFoundErr (#657)
This commit is contained in:
parent
a196d0320e
commit
d3c7149942
1 changed files with 4 additions and 1 deletions
|
|
@ -22,6 +22,7 @@ import (
|
|||
"encoding/binary"
|
||||
"errors"
|
||||
|
||||
"github.com/cockroachdb/pebble"
|
||||
leveldb "github.com/syndtr/goleveldb/leveldb/errors"
|
||||
|
||||
"github.com/ethereum/go-ethereum/common"
|
||||
|
|
@ -188,7 +189,9 @@ func encodeBigEndian(index uint64) []byte {
|
|||
}
|
||||
|
||||
func isNotFoundErr(err error) bool {
|
||||
return errors.Is(err, leveldb.ErrNotFound) || errors.Is(err, memorydb.ErrMemorydbNotFound)
|
||||
return errors.Is(err, leveldb.ErrNotFound) ||
|
||||
errors.Is(err, memorydb.ErrMemorydbNotFound) ||
|
||||
errors.Is(err, pebble.ErrNotFound)
|
||||
}
|
||||
|
||||
// headerKeyPrefix = headerPrefix + num (uint64 big endian)
|
||||
|
|
|
|||
Loading…
Reference in a new issue