Skip to content

Commit e7cf16d

Browse files
committed
fix: update database initialization to use configurable path
Signed-off-by: tbxark <[email protected]>
1 parent af7a6f3 commit e7cf16d

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

cache/badgerdb/database.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ type Database struct {
1515
}
1616

1717
func NewDatabase(config *Config) (*Database, error) {
18-
db, err := badger.Open(badger.DefaultOptions("/tmp/badger"))
18+
db, err := badger.Open(badger.DefaultOptions(config.Path))
1919
if err != nil {
2020
return nil, err
2121
}

layout/go.mod

-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ require (
1010
entgo.io/ent v0.14.2
1111
github.com/TBXark/confstore v0.0.0-20250213133642-966f3d3fb351
1212
github.com/TBXark/sphere v0.0.0-20250220092258-cd61b708e243
13-
github.com/TBXark/sphere/contrib/json-gen-proto v0.0.0-20250220092258-cd61b708e243
1413
github.com/alitto/pond/v2 v2.2.0
1514
github.com/gin-contrib/gzip v1.2.2
1615
github.com/gin-gonic/gin v1.10.0

0 commit comments

Comments
 (0)