Skip to content

Commit

Permalink
Merge jr.deletedKeys two for loops together
Browse files Browse the repository at this point in the history
  • Loading branch information
qdm12 committed Jan 6, 2022
1 parent dd46af2 commit 08c9d92
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions dot/state/pruner/pruner.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,12 +170,9 @@ func (p *FullNode) addDeathRow(jr *journalRecord, blockNum int64) {
p.processInsertedKeys(jr.insertedHashesSet, jr.blockHash)

// add deleted keys from journal to death index
deletedKeys := make(map[common.Hash]int64, len(jr.deletedHashesSet))
for k := range jr.deletedHashesSet {
p.deathIndex[k] = blockNum
}

deletedKeys := make(map[common.Hash]int64)
for k := range jr.deletedHashesSet {
deletedKeys[k] = blockNum
}

Expand Down

0 comments on commit 08c9d92

Please sign in to comment.