forked from LBRYCommunity/lbry-sdk
fixing claim updates
This commit is contained in:
parent
9535a24706
commit
e9bab33e2a
1 changed files with 2 additions and 6 deletions
|
@ -462,10 +462,7 @@ class Wallet(object):
|
||||||
|
|
||||||
def _claim_or_update(claim, metadata, _bid):
|
def _claim_or_update(claim, metadata, _bid):
|
||||||
if not claim:
|
if not claim:
|
||||||
log.info("No claim yet, making a new one")
|
log.info("No own claim yet, making a new one")
|
||||||
return self._send_name_claim(name, metadata, _bid)
|
|
||||||
if not claim['is_mine']:
|
|
||||||
log.info("Making a contesting claim")
|
|
||||||
return self._send_name_claim(name, metadata, _bid)
|
return self._send_name_claim(name, metadata, _bid)
|
||||||
else:
|
else:
|
||||||
log.info("Updating over own claim")
|
log.info("Updating over own claim")
|
||||||
|
@ -474,8 +471,7 @@ class Wallet(object):
|
||||||
return d
|
return d
|
||||||
|
|
||||||
meta = Metadata(m)
|
meta = Metadata(m)
|
||||||
|
d = self.get_my_claim(name)
|
||||||
d = self.get_claim_info(name)
|
|
||||||
d.addCallback(lambda claim: _claim_or_update(claim, meta, bid))
|
d.addCallback(lambda claim: _claim_or_update(claim, meta, bid))
|
||||||
d.addCallback(lambda txid: _save_metadata(txid, meta))
|
d.addCallback(lambda txid: _save_metadata(txid, meta))
|
||||||
return d
|
return d
|
||||||
|
|
Loading…
Add table
Reference in a new issue