Skip to content
Snippets Groups Projects
Commit ec365663 authored by Thorge Petersen's avatar Thorge Petersen
Browse files

Removed typing in odsh_has_more_facets

parent ed80c273
No related branches found
No related tags found
1 merge request!50Upgraded to CKAN 2.10
......@@ -16,15 +16,11 @@ import urllib.error
import hashlib
import re
import csv
import urllib.request
import urllib.error
import urllib.parse
from ckan.common import config, request, g, c
from urllib.parse import urlsplit, urlunsplit
import ckan.lib.helpers as helpers
from collections import OrderedDict
import pkg_resources
from typing import Any, Optional
CKAN_TYPES = {'http://dcat-ap.de/def/datasetTypes/collection': 'collection'}
......@@ -248,10 +244,7 @@ def presorted_license_options(existing_license_id=None):
for license_id in license_ids]
def odsh_has_more_facets(facet: str,
search_facets: dict[str, dict[str, Any]],
limit: Optional[int] = None,
exclude_active: bool = False) -> bool:
def odsh_has_more_facets(facet, search_facets, limit=None, exclude_active=False):
facets = []
for facet_item in search_facets.get(facet)['items']:
if not len(facet_item['name'].strip()) or facet_item['count'] == 0:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment