diff --git a/lbry/db/queries/search.py b/lbry/db/queries/search.py index 4363003e4..42c5686c5 100644 --- a/lbry/db/queries/search.py +++ b/lbry/db/queries/search.py @@ -226,7 +226,7 @@ def protobuf_search_claims(**constraints) -> str: def search_claims(**constraints) -> Tuple[List[Output], Optional[int], Optional[Censor]]: total = None - if constraints.pop('include_totals', False): + if constraints.pop('include_total', False): total = search_claim_count(**constraints) constraints['offset'] = abs(constraints.get('offset', 0)) constraints['limit'] = min(abs(constraints.get('limit', 10)), 50) diff --git a/lbry/service/api.py b/lbry/service/api.py index 60118d669..7affa0bc2 100644 --- a/lbry/service/api.py +++ b/lbry/service/api.py @@ -1631,7 +1631,7 @@ class API: page_size = min(abs(pagination['page_size'] or DEFAULT_PAGE_SIZE), 50) claim_filter_dict.update({ 'offset': page_size * (page_num - 1), 'limit': page_size, - 'include_totals': pagination['include_totals'], + 'include_total': pagination['include_total'], 'order_by': order_by }) if protobuf: @@ -1645,7 +1645,7 @@ class API: "page": page_num, "page_size": page_size } - if pagination['include_totals']: + if pagination['include_total']: d['total_pages'] = int((result.total + (page_size - 1)) / page_size) d['total_items'] = result.total return d