Skip to content

Commit

Permalink
no_panic_be_happy (#1586)
Browse files Browse the repository at this point in the history
  • Loading branch information
AskAlexSharov committed Apr 6, 2021
1 parent bb25047 commit de4f680
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ethdb/kv_lmdb.go
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ func (db *LmdbKV) CollectMetrics() {
tableGcEntries.Update(int64(stat.Entries))
return nil
}); err != nil {
panic(err)
log.Error("collecting metrics failed", "err", err)
}
}

Expand Down
2 changes: 1 addition & 1 deletion ethdb/kv_mdbx.go
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ func (db *MdbxKV) CollectMetrics() {
tableGcEntries.Update(int64(stat.Entries))
return nil
}); err != nil {
panic(err)
log.Error("collecting metrics failed", "err", err)
}
}

Expand Down
2 changes: 1 addition & 1 deletion ethdb/object_db.go
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ func (db *ObjectDatabase) NewBatch() DbWithPendingMutations {
func (db *ObjectDatabase) Begin(ctx context.Context, flags TxFlags) (DbWithPendingMutations, error) {
batch := &TxDb{db: db}
if err := batch.begin(ctx, flags); err != nil {
panic(err)
return batch, err
}
return batch, nil
}
Expand Down

0 comments on commit de4f680

Please sign in to comment.