Skip to content

Commit

Permalink
gateway: fetcher: need to use dagpb.AddSupportToChooser
Browse files Browse the repository at this point in the history
  • Loading branch information
hsanjuan committed Oct 13, 2023
1 parent a249c8a commit 2f47153
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion gateway/blocks_backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,9 @@ func NewBlocksBackend(blockService blockservice.BlockService, opts ...BlocksBack
r = compiledOptions.r
if r == nil {
// Setup the UnixFS resolver.
fetcher := bsfetcher.NewFetcherConfig(blockService).WithReifier(unixfsnode.Reify)
fetcherCfg := bsfetcher.NewFetcherConfig(blockService)
fetcherCfg.PrototypeChooser = dagpb.AddSupportToChooser(bsfetcher.DefaultPrototypeChooser)
fetcher := fetcherCfg.WithReifier(unixfsnode.Reify)
r = resolver.NewBasicResolver(fetcher)
}

Expand Down

0 comments on commit 2f47153

Please sign in to comment.