From 21241b98a476390ab6d970f162c41caa4b835258 Mon Sep 17 00:00:00 2001 From: Victor Shyba Date: Sun, 21 Apr 2019 22:40:39 -0300 Subject: [PATCH] workaround for having new encoder fields on resolve so app can use them --- lbrynet/wallet/resolve.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/lbrynet/wallet/resolve.py b/lbrynet/wallet/resolve.py index d2d41e2ed..a4f3b72fb 100644 --- a/lbrynet/wallet/resolve.py +++ b/lbrynet/wallet/resolve.py @@ -169,6 +169,15 @@ class Resolver: claim_result['signature_is_valid'] = validate_claim_signature_and_get_channel_name( claim_result, certificate, self.ledger, claim_tx=claim_tx, cert_tx=cert_tx ) + # fixme: workaround while json encoder isnt used here + if cert_tx: + channel_txo = cert_tx.outputs[certificate['nout']] + claim_result['signing_channel'] = { + 'name': channel_txo.claim_name, + 'claim_id': channel_txo.claim_id, + 'value': channel_txo.claim + } + claim_result['is_channel_signature_valid'] = claim_result['signature_is_valid'] if 'amount' in claim_result: claim_result['amount'] = dewies_to_lbc(claim_result['amount'])