From 3b92993ef6fb40e3d956056ea778a91dacfdd399 Mon Sep 17 00:00:00 2001 From: Mizaki Date: Sat, 3 Jun 2023 00:11:40 +0100 Subject: [PATCH] Remove country name code --- comicapi/utils.py | 29 ----------------------------- 1 file changed, 29 deletions(-) diff --git a/comicapi/utils.py b/comicapi/utils.py index 650edce..7499c9a 100644 --- a/comicapi/utils.py +++ b/comicapi/utils.py @@ -253,35 +253,6 @@ def get_country_from_iso(iso: str | None) -> str | None: return countries[iso] -def get_country_iso(string: str | None) -> str | None: - if string is None: - return None - - try: - country = pycountry.countries.lookup(string) - if country: - # Assume first entry is correct - return country[0].alpha_2 - except LookupError: - pass - return None - - -def get_country_iso_name(string: str | None) -> str | None: - """Return country's ISO name from "other" name""" - if string is None: - return None - - try: - country = pycountry.countries.search_fuzzy(string) - if country: - # Assume first entry is correct - return country[0].name - except LookupError: - pass - return None - - def get_publisher(publisher: str) -> tuple[str, str]: imprint = ""