mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
ethdb/memorydb: allow noop compact on memdb
This commit is contained in:
parent
7f3362595a
commit
f0459c0512
1 changed files with 3 additions and 2 deletions
|
|
@ -197,9 +197,10 @@ func (db *Database) Stat(property string) (string, error) {
|
|||
return "", errors.New("unknown property")
|
||||
}
|
||||
|
||||
// Compact is not supported on a memory database.
|
||||
// Compact is not supported on a memory database, but there's no need either as
|
||||
// a memory database doens't waste space anyway.
|
||||
func (db *Database) Compact(start []byte, limit []byte) error {
|
||||
return errors.New("unsupported operation")
|
||||
return nil
|
||||
}
|
||||
|
||||
// Len returns the number of entries currently present in the memory database.
|
||||
|
|
|
|||
Loading…
Reference in a new issue