From 935168c02425999a417656bc87723de60815332a Mon Sep 17 00:00:00 2001 From: Li-shi-ling <114913764+Li-shi-ling@users.noreply.github.com> Date: Fri, 13 Feb 2026 13:15:08 +0800 Subject: [PATCH] fix-correct-FIRST_NOTICE.md-locale-path-resolution (#5083) (#5082) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix:修改配置文件目录 * fix:添加备选的FIRST_NOTICE.zh-CN.md用于兼容 --- astrbot/dashboard/routes/stat.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/astrbot/dashboard/routes/stat.py b/astrbot/dashboard/routes/stat.py index 666eb4c8..532238ac 100644 --- a/astrbot/dashboard/routes/stat.py +++ b/astrbot/dashboard/routes/stat.py @@ -295,14 +295,15 @@ class StatRoute(Route): if locale: candidates.append(base_path / f"FIRST_NOTICE.{locale}.md") if locale.lower().startswith("zh"): + candidates.append(base_path / "FIRST_NOTICE.md") candidates.append(base_path / "FIRST_NOTICE.zh-CN.md") elif locale.lower().startswith("en"): candidates.append(base_path / "FIRST_NOTICE.en-US.md") candidates.extend( [ - base_path / "FIRST_NOTICE.en-US.md", base_path / "FIRST_NOTICE.md", + base_path / "FIRST_NOTICE.en-US.md", ], )