Skip to content

Commit

Permalink
remove func
Browse files Browse the repository at this point in the history
  • Loading branch information
cristaloleg committed May 31, 2024
1 parent d3e4a5a commit 8aa64f8
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions store/store.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,21 +64,6 @@ func NewStore[H header.Header[H]](ds datastore.Batching, opts ...Option) (*Store
return newStore[H](ds, opts...)
}

// NewStoreWithHead initiates a new Store and forcefully sets a given trusted header as head.
func NewStoreWithHead[H header.Header[H]](
ctx context.Context,
ds datastore.Batching,
head H,
opts ...Option,
) (*Store[H], error) {
store, err := newStore[H](ds, opts...)
if err != nil {
return nil, err
}

return store, store.Init(ctx, head)
}

func newStore[H header.Header[H]](ds datastore.Batching, opts ...Option) (*Store[H], error) {
params := DefaultParameters()
for _, opt := range opts {
Expand Down

0 comments on commit 8aa64f8

Please sign in to comment.