Update iterator.go

This commit is contained in:
miles 2024-03-19 22:23:42 +08:00 committed by GitHub
parent 2a60aa7841
commit 9d75b7e6be
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -89,7 +89,7 @@ func (dl *diffLayer) AccountIterator(seek common.Hash) AccountIterator {
index := sort.Search(len(hashes), func(i int) bool {
return bytes.Compare(seek[:], hashes[i][:]) <= 0
})
// Assemble and returned the already sought iterator
// Assemble and returned the already seeked iterator
return &diffAccountIterator{
layer: dl,
keys: hashes[index:],
@ -255,7 +255,7 @@ func (dl *diffLayer) StorageIterator(account common.Hash, seek common.Hash) (Sto
index := sort.Search(len(hashes), func(i int) bool {
return bytes.Compare(seek[:], hashes[i][:]) <= 0
})
// Assemble and returned the already sought iterator
// Assemble and returned the already seeked iterator
return &diffStorageIterator{
layer: dl,
account: account,