From 426825d475b76a9a3519be74f74ef72df7cd8b35 Mon Sep 17 00:00:00 2001 From: JOJO <1498581755@qq.com> Date: Wed, 24 Jun 2026 01:33:04 +0800 Subject: [PATCH] =?UTF-8?q?fix(server):=20=E4=BF=AE=E6=AD=A3/api/app/versi?= =?UTF-8?q?on=E7=9A=84project=5Froot=E8=B7=AF=E5=BE=84=E8=AE=A1=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/status/app.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/status/app.py b/server/status/app.py index bae358a..dc00b53 100644 --- a/server/status/app.py +++ b/server/status/app.py @@ -41,7 +41,7 @@ import server.state as state @status_bp.route('/api/app/version') @api_login_required def get_app_version_info(): - project_root = Path(__file__).resolve().parent.parent + project_root = Path(__file__).resolve().parent.parent.parent version_code, version_name = _parse_android_version_from_gradle(project_root) apk_path = _resolve_android_apk_path(project_root) apk_exists = apk_path.exists() @@ -73,7 +73,7 @@ def get_app_version_info(): @status_bp.route('/api/app/apk/latest') def download_latest_apk(): - project_root = Path(__file__).resolve().parent.parent + project_root = Path(__file__).resolve().parent.parent.parent apk_path = _resolve_android_apk_path(project_root) if not apk_path.exists(): return jsonify({"success": False, "error": "APK 不存在,请先构建 release 包"}), 404