Simplify error handling in history inspection

Remove explicit error for no history available.
This commit is contained in:
rjl493456442 2025-11-13 14:49:46 +08:00 committed by GitHub
parent 9cb3931d75
commit 49e72a828d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -143,10 +143,6 @@ func historyRange(freezer ethdb.AncientReader) (uint64, uint64, error) {
if err != nil {
return 0, 0, err
}
// If there is no history available, return an explicit error.
if head == tail {
return 0, 0, fmt.Errorf("no history available")
}
last := head
fh, err := readStateHistory(freezer, first)