There was an error while loading. Please reload this page.
1 parent 21dcf63 commit 58a85a4Copy full SHA for 58a85a4
1 file changed
astrbot/dashboard/server.py
@@ -32,9 +32,7 @@
32
from .plugin_page_auth import PluginPageAuth
33
from .services.auth_service import DASHBOARD_JWT_COOKIE_NAME
34
35
-# Windows 下 Python mimetypes 会按系统注册表将 .svg 映射为 image/svg,
36
-# 导致 WebUI 静态资源(favicon.svg 等)返回非标准 MIME 类型,Chrome 无法渲染。
37
-# 显式覆盖为标准类型,使其在任意平台上行为一致。
+# Windows 的 mimetypes 会把 .svg 映射成非标准的 image/svg,这里强制覆盖为标准类型
38
mimetypes.add_type("image/svg+xml", ".svg", strict=True)
39
40
_RATE_LIMITED_ENDPOINTS: frozenset = frozenset(
0 commit comments