🐛 文件下载逻辑修改

This commit is contained in:
AkashiCoin
2024-09-03 17:13:31 +08:00
parent 682d19aa2b
commit ce97dedc5f
3 changed files with 22 additions and 21 deletions
@@ -70,11 +70,7 @@ class RepoInfo(BaseModel):
"""获取最快下载地址格式"""
raw_format = "https://raw.githubusercontent.com/{owner}/{repo}/{branch}/{path}"
patterns: dict[str, str] = {
(
"https://raw.githubusercontent.com"
"/zhenxun-org/zhenxun_bot_plugins/main"
"/plugins.json"
): raw_format,
"https://raw.githubusercontent.com/": raw_format,
"https://ghproxy.cc/": f"https://ghproxy.cc/{raw_format}",
"https://mirror.ghproxy.com/": f"https://mirror.ghproxy.com/{raw_format}",
"https://gh-proxy.com/": f"https://gh-proxy.com/{raw_format}",