From 4b59b997eac6b43a54d11c6114dbd278fb963174 Mon Sep 17 00:00:00 2001 From: projectdx Date: Sat, 3 Jan 2026 21:00:48 +0900 Subject: [PATCH] fix: Correct regex and string quoting in mod_ohli24.py --- info.yaml | 2 +- mod_ohli24.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/info.yaml b/info.yaml index 3b36b86..a317118 100644 --- a/info.yaml +++ b/info.yaml @@ -1,5 +1,5 @@ title: "애니 다운로더" -version: "0.5.6" +version: "0.5.7" package_name: "anime_downloader" developer: "projectdx" description: "anime downloader" diff --git a/mod_ohli24.py b/mod_ohli24.py index 0e394b5..3d18e9e 100644 --- a/mod_ohli24.py +++ b/mod_ohli24.py @@ -912,7 +912,7 @@ class LogicOhli24(AnimeModuleBase): logger.info("Found item-subject in HTML") else: logger.warning("item-subject NOT found in HTML") - if "itemprop="image"" in response_data: + if 'itemprop="image"' in response_data: logger.info("Found itemprop=image in HTML") else: logger.warning("itemprop=image NOT found in HTML") @@ -2417,8 +2417,8 @@ class Ohli24QueueEntity(AnimeQueueEntity): if html_content: # m3u8 URL 패턴 찾기 m3u8_patterns = [ - re.compile(r"file:\s*['"]([^'"]*(?:\.m3u8|master\.txt)[^'"]*)['"]"), - re.compile(r"['"]([^'"]*(?:\.m3u8|master\.txt)[^'"]*)['"]"), + re.compile(r"file:\s*['\"]([^'\"]*(?:\.m3u8|master\.txt)[^'\"]*)['\"]"), + re.compile(r"['\"]([^'\"]*(?:\.m3u8|master\.txt)[^'\"]*)['\"]"), ] for pattern in m3u8_patterns: match = pattern.search(html_content) @@ -2437,7 +2437,7 @@ class Ohli24QueueEntity(AnimeQueueEntity): logger.debug(f"HTML Content (First 2000 chars): {html_content[:2000]}") if not vtt_url: - vtt_match = re.search(r"['"]([^'"]*\.vtt[^'"]*)['"]", html_content) + vtt_match = re.search(r"['\"]([^'\"]*\.vtt[^'\"]*)['\"]", html_content) if vtt_match: vtt_url = vtt_match.group(1) if vtt_url.startswith("//"): vtt_url = "https:" + vtt_url