fix subscribe_hash
This commit is contained in:
parent
888e9918a6
commit
43e50f7f04
1 changed files with 2 additions and 1 deletions
|
@ -164,4 +164,5 @@ class TrackerClient:
|
|||
|
||||
def subscribe_hash(hash, on_data):
|
||||
TrackerClient.EVENT_CONTROLLER.add(('search', bytes.fromhex(hash)))
|
||||
TrackerClient.EVENT_CONTROLLER.stream.listen(lambda request: on_data(request[1]) if request[0] == hash else None)
|
||||
TrackerClient.EVENT_CONTROLLER.stream.listen(
|
||||
lambda request: on_data(request[1]) if request[0].hex() == hash else None)
|
||||
|
|
Loading…
Reference in a new issue