mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-22 19:50:36 +00:00
21 lines
274 B
Go
21 lines
274 B
Go
package ethdb
|
|
|
|
import (
|
|
"os"
|
|
|
|
"path/filepath"
|
|
|
|
"github.com/ethereum/go-ethereum/common"
|
|
)
|
|
|
|
func newDb() *LDBDatabase {
|
|
file := filepath.Join("/", "tmp", "ldbtesttmpfile")
|
|
if common.FileExist(file) {
|
|
os.RemoveAll(file)
|
|
}
|
|
|
|
db, _ := NewLDBDatabase(file)
|
|
|
|
return db
|
|
}
|