Skip to content

Commit

Permalink
gateway: clarify WithResolver is only used by BlocksGateway
Browse files Browse the repository at this point in the history
  • Loading branch information
hacdias committed Apr 17, 2024
1 parent 7f95068 commit 397f7bc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions gateway/backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ import (
type backendOptions struct {
ns namesys.NameSystem
vs routing.ValueStore
r resolver.Resolver

// Only used by [BlocksBackend]:
r resolver.Resolver

// Only used by [CarBackend]:
promRegistry prometheus.Registerer
Expand All @@ -46,7 +48,7 @@ func WithValueStore(vs routing.ValueStore) BackendOption {
}
}

// WithResolver sets the [resolver.Resolver] to use with the different backends.
// WithResolver sets the [resolver.Resolver] to use with to use with [BlocksBackend].
func WithResolver(r resolver.Resolver) BackendOption {
return func(opts *backendOptions) error {
opts.r = r
Expand Down

0 comments on commit 397f7bc

Please sign in to comment.