Skip to content

Commit

Permalink
fix pruner provide
Browse files Browse the repository at this point in the history
  • Loading branch information
Wondertan committed May 14, 2024
1 parent 5aac80d commit 1c5532d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion nodebuilder/pruner/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,9 @@ func ConstructModule(tp node.Type, cfg *Config) fx.Option {
}),
)
case node.Light:
fx.Provide(light.NewPruner)
return fx.Module("prune",
baseComponents,
fx.Provide(light.NewPruner),
fx.Supply(light.Window),
)
default:
Expand Down
3 changes: 2 additions & 1 deletion pruner/light/pruner.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"github.com/ipfs/go-datastore"

"github.com/celestiaorg/celestia-node/header"
"github.com/celestiaorg/celestia-node/pruner"
"github.com/celestiaorg/celestia-node/share"
"github.com/celestiaorg/celestia-node/share/ipld"
)
Expand All @@ -17,7 +18,7 @@ type Pruner struct {
ds datastore.Datastore
}

func NewPruner(bstore blockstore.Blockstore, ds datastore.Datastore) *Pruner {
func NewPruner(bstore blockstore.Blockstore, ds datastore.Batching) pruner.Pruner {
return &Pruner{bserv: blockservice.New(bstore, nil), ds: ds}
}

Expand Down

0 comments on commit 1c5532d

Please sign in to comment.