mirror of
https://github.com/LBRYFoundation/lbry-sdk.git
synced 2025-09-01 09:45:13 +00:00
Merge pull request #3293 from lbryio/fix-block-processor-crash-invalid-fee
fix invalid claim fees breaking the block processor
This commit is contained in:
commit
8c9710c76c
1 changed files with 2 additions and 1 deletions
|
@ -406,6 +406,7 @@ class SQLDB:
|
||||||
if isinstance(fee.currency, str):
|
if isinstance(fee.currency, str):
|
||||||
claim_record['fee_currency'] = fee.currency.lower()
|
claim_record['fee_currency'] = fee.currency.lower()
|
||||||
if isinstance(fee.amount, Decimal):
|
if isinstance(fee.amount, Decimal):
|
||||||
|
if fee.amount >= 0 and int(fee.amount*1000) < 9223372036854775807:
|
||||||
claim_record['fee_amount'] = int(fee.amount*1000)
|
claim_record['fee_amount'] = int(fee.amount*1000)
|
||||||
elif claim.is_repost:
|
elif claim.is_repost:
|
||||||
claim_record['claim_type'] = CLAIM_TYPES['repost']
|
claim_record['claim_type'] = CLAIM_TYPES['repost']
|
||||||
|
|
Loading…
Add table
Reference in a new issue