Less extensive multi extension regex

This commit is contained in:
Georges-Antoine Assi
2023-11-04 23:12:40 -04:00
parent b99cce243b
commit 015e5927d6
2 changed files with 2 additions and 2 deletions

View File

@@ -171,7 +171,7 @@ class IGDBHandler:
search_term = get_search_term(file_name)
# Support for PS2 OPL flename format
match = re.match(PS2_OPL_REGEX, search_term)
match = re.match(PS2_OPL_REGEX, file_name)
if p_igdb_id == PS2_IGDB_ID and match:
serial_code = match.group(1)

View File

@@ -59,7 +59,7 @@ REGIONS_BY_SHORTCODE = {region[0].lower(): region[1] for region in REGIONS}
REGIONS_NAME_KEYS = [region[1].lower() for region in REGIONS]
TAG_REGEX = r"\(([^)]+)\)|\[([^]]+)\]"
EXTENSION_REGEX = r"\.(\w+(\.\w+)*)$"
EXTENSION_REGEX = r"\.([a-z]+(\.\w+)*)$"
def parse_tags(file_name: str) -> tuple: