mirror of
https://github.com/ipfs/kubo.git
synced 2025-09-09 17:22:21 +08:00
add filters from config to addr filter in swarm
License: MIT Signed-off-by: Jeromy <jeromyj@gmail.com>
This commit is contained in:
@ -533,6 +533,10 @@ func constructPeerHost(ctx context.Context, id peer.ID, ps peer.Peerstore, bwr m
|
||||
return nil, err
|
||||
}
|
||||
|
||||
for _, f := range fs {
|
||||
network.Swarm().Filters.AddDialFilter(f)
|
||||
}
|
||||
|
||||
host := p2pbhost.New(network, p2pbhost.NATPortMap, bwr)
|
||||
|
||||
return host, nil
|
||||
|
Reference in New Issue
Block a user