forked from LBRYCommunity/lbry-sdk
add fixed peers immediately if the dht has no peers
This commit is contained in:
parent
e8a1953815
commit
f9fd62c214
1 changed files with 5 additions and 1 deletions
|
@ -83,7 +83,11 @@ class StreamDownloader(StreamAssembler):
|
|||
])
|
||||
if self.config.reflector_servers:
|
||||
self.fixed_peers_handle = self.loop.call_later(
|
||||
self.config.fixed_peer_delay if 'dht' not in self.config.components_to_skip else 0.0,
|
||||
self.config.fixed_peer_delay if (
|
||||
'dht' not in self.config.components_to_skip
|
||||
and self.node
|
||||
and len(self.node.protocol.routing_table.get_peers())
|
||||
) else 0.0,
|
||||
self.loop.create_task, _add_fixed_peers()
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue