Fix replay_keys

Counters should never have an entry with zero value.
This commit is contained in:
Gav Wood 2016-03-07 06:58:43 +01:00
parent 4230fdfffe
commit 0980c7130a

View File

@ -191,7 +191,9 @@ impl JournalDB {
// this is the first entry for this node in the journal. // this is the first entry for this node in the journal.
// it is initialised to 1 if it was already in. // it is initialised to 1 if it was already in.
counters.insert(h.clone(), if Self::is_already_in(backing, h) {1} else {0}); if Self::is_already_in(backing, h) {
counters.insert(h.clone(), 1);
}
} }
} }