diff options
author | Wolfgang Müller | 2025-01-16 18:24:09 +0100 |
---|---|---|
committer | Wolfgang Müller | 2025-01-16 18:32:02 +0100 |
commit | 9dea5cbc01e2d447d77d5fb205acb1d17fe9c55f (patch) | |
tree | 2e54f49c7bb9ffb28030b5c79a99121d90661240 /src | |
parent | 12f8bfbf4a0d93b2fca946705da199591f744a2c (diff) | |
download | hircine-trunk.tar.gz |
Diffstat (limited to 'src')
-rw-r--r-- | src/hircine/plugins/scrapers/anchira.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/hircine/plugins/scrapers/anchira.py b/src/hircine/plugins/scrapers/anchira.py index bb60ac9..1e89ffb 100644 --- a/src/hircine/plugins/scrapers/anchira.py +++ b/src/hircine/plugins/scrapers/anchira.py @@ -19,7 +19,8 @@ from hircine.scraper.types import ( ) from hircine.scraper.utils import open_archive_file, parse_dict -SOURCE_REGEX = re.compile(r"^https?://anchira\.to/g/") +ANCHIRA_REGEX = re.compile(r"^https?://anchira\.to/g/") +NEXUS_REGEX = re.compile(r"^https?://hentainexus\.com/") class AnchiraYamlScraper(Scraper): @@ -45,9 +46,10 @@ class AnchiraYamlScraper(Scraper): self.data = self.load() source = self.data.get("Source") - if source and re.match(SOURCE_REGEX, source): - self.is_available = True - elif not source: + if source: + if re.match(ANCHIRA_REGEX, source) or re.match(NEXUS_REGEX, source): + self.is_available = True + else: # heuristic, but should be good enough url = self.data.get("URL") parody = self.data.get("Parody") |