From d7173f638a4e5066d9d35b2f5c773d5d35d2fbb6 Mon Sep 17 00:00:00 2001 From: swfarnsworth Date: Sun, 12 Sep 2021 20:55:42 -0400 Subject: Remove wildcard asterisks in URL. This is no longer necessary as empty columns are treated as all being selected. --- pydis_site/apps/resources/views/resources.py | 8 -------- 1 file changed, 8 deletions(-) (limited to 'pydis_site/apps') diff --git a/pydis_site/apps/resources/views/resources.py b/pydis_site/apps/resources/views/resources.py index a08f1d15..5b3cccab 100644 --- a/pydis_site/apps/resources/views/resources.py +++ b/pydis_site/apps/resources/views/resources.py @@ -8,10 +8,6 @@ RESOURCE_META_TAGS = {k: set(v) for k, v in RESOURCE_TABLE.items()} def _parse_checkbox_options(options: str) -> set[str]: """Split up the comma separated query parameters for checkbox options into a list.""" - if not options: - return set() - if options == '*': - return {'*'} return set(options.split(",")[:-1]) @@ -27,10 +23,6 @@ def resource_view(request: HttpRequest) -> HttpResponse: ) } - # This allows for an asterisk in the URL to be a wildcard for that selection - checkbox_options = {k: (v if v != {'*'} else RESOURCE_META_TAGS[k]) - for k, v in checkbox_options.items()} - topics = sorted(RESOURCE_META_TAGS.get("topics")) return render( -- cgit v1.2.3