From 70d9f4cf7954d786e8d64585c5dba5c68bfd4558 Mon Sep 17 00:00:00 2001 From: Lex Berezhny Date: Mon, 10 Aug 2020 18:53:00 -0400 Subject: [PATCH] convert claim_id to channel_hash --- lbry/db/queries/search.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lbry/db/queries/search.py b/lbry/db/queries/search.py index 1bfcd80d9..cfa77c09d 100644 --- a/lbry/db/queries/search.py +++ b/lbry/db/queries/search.py @@ -43,6 +43,8 @@ def search_supports(**constraints) -> Tuple[List[Output], Optional[int]]: total = None if constraints.pop('include_total', False): total = search_support_count(**constraints) + if 'claim_id' in constraints: + constraints['claim_hash'] = unhexlify(constraints.pop('claim_id'))[::-1] rows = context().fetchall(select_supports(**constraints)) txos = rows_to_txos(rows, include_tx=False) return txos, total