forked from LBRYCommunity/lbry-sdk
call blob_completed after receiving blob
This commit is contained in:
parent
f5508fcdf1
commit
c046cd02d5
2 changed files with 2 additions and 0 deletions
|
@ -44,6 +44,7 @@ class BlobAvailabilityHandler(object):
|
|||
d = self._get_available_blobs(queries[self.query_identifiers[0]])
|
||||
|
||||
def set_field(available_blobs):
|
||||
log.debug("available blobs: %s", str(available_blobs))
|
||||
return {'available_blobs': available_blobs}
|
||||
|
||||
d.addCallback(set_field)
|
||||
|
|
|
@ -89,6 +89,7 @@ class ReflectorServer(Protocol):
|
|||
else:
|
||||
self.incoming_blob = blob
|
||||
self.blob_finished_d, self.blob_write, self.cancel_write = blob.open_for_writing(self.peer)
|
||||
self.blob_finished_d.addCallback(lambda _: self.blob_manager.blob_completed(blob))
|
||||
return {'send_blob': True}
|
||||
|
||||
def close_blob(self):
|
||||
|
|
Loading…
Add table
Reference in a new issue