Merge branch 'main' into 3.0-dev

This commit is contained in:
EstrellaXD
2023-05-06 21:45:36 +08:00
5 changed files with 6 additions and 6 deletions

View File

@@ -14,3 +14,4 @@ class RSSLink(str):
PLATFORM = "Windows" if "\\" in settings.downloader.path else "Unix"
MIKANANI_URL = "mikanani.me"

View File

@@ -80,4 +80,3 @@ else:

View File

@@ -86,16 +86,16 @@ class APIProcess:
return json_config.load(CONFIG_PATH)
def get_rss(self, full_path: str):
url = f"https://mikanime.tv/RSS/{full_path}"
url = f"https://mikanani.me/RSS/{full_path}"
custom_url = self._custom_url
if "://" not in custom_url:
custom_url = f"https://{custom_url}"
with RequestContent() as request:
content = request.get_html(url)
return re.sub(r"https://mikanime.tv", custom_url, content)
return re.sub(r"https://mikanani.me", custom_url, content)
@staticmethod
def get_torrent(full_path):
url = f"https://mikanime.tv/Download/{full_path}"
url = f"https://mikanani.me/Download/{full_path}"
with RequestContent() as request:
return request.get_content(url)

View File

@@ -22,7 +22,7 @@ class RSSParser(BaseModel):
enable: bool = Field(True, description="Enable RSS parser")
type: str = Field("mikan", description="RSS parser type")
token: str = Field("token", description="RSS parser token")
custom_url: str = Field("mikanime.tv", description="Custom RSS host url")
custom_url: str = Field("mikanani.me", description="Custom RSS host url")
enable_tmdb: bool = Field(False, description="Enable TMDB")
filter: list[str] = Field(["720", r"\d+-\d"], description="Filter")
language: str = "zh"