Skip to content

The only downloader you need. 下载器的集大成者。

refactor(android): 单一事实来源与架构简化

XiaoYouChReb25900ce4f8
diff --git a/app/config/cfg.py b/app/config/cfg.py
index 15118e08..0c945d47 100644
--- a/app/config/cfg.py
+++ b/app/config/cfg.py
@@ -81,7 +81,10 @@ class ProxyValidator(ConfigValidator):
)
def validate(self, value: str) -> bool:
- return bool(self.PATTERN.match(value)) or value in {"Auto", "Off"}
+ if value in {"Auto", "Off"}:
+ return True
+ matched = self.PATTERN.match(value)
+ return matched is not None and 1 <= int(matched["port"]) <= 65535
def correct(self, value) -> str:
return value if self.validate(value) else "Auto"
diff --git a/app/config/constants.py b/app/config/constants.py
index e00f4fd7..b9f8350c 100644
--- a/app/config/constants.py
+++ b/app/config/constants.py
@@ -1,6 +1,6 @@
YEAR = 2026
AUTHOR = "XiaoYouChR"
-VERSION = "4.3.7"
+VERSION = "4.3.8"
BUILD_VERSION = VERSION.split("-")[0]
DESKTOP_ID = "io.github.xiaoyouchr.GhostDownloader"
DESKTOP_OBJECT_PATH = "/" + DESKTOP_ID.replace(".", "/")
diff --git a/features/bili_pack/android.py b/features/bili_pack/android.py
index e555745f..d092689c 100644
--- a/features/bili_pack/android.py
+++ b/features/bili_pack/android.py
@@ -34,7 +34,6 @@ def draftFields(task) -> dict:
"isAudioEnabled": task.isAudioEnabled,
"isCoverEnabled": task.isCoverEnabled,
"hasCover": bool(task.coverUrl),
- "canRenameFiles": True,
"duration": page._duration if page else 0,
"startTime": page.startTime if page else 0,
"endTime": page.endTime if page else 0,