进一步的 kvmd 国际化(汉化)支持,添加配置入口

yaml 配置示例:
```
languages:
    console: zh
    web: zh
```
This commit is contained in:
mofeng-git
2024-08-14 22:54:12 +08:00
parent 5b25b3661f
commit 35397c5414
47 changed files with 567 additions and 181 deletions

View File

@@ -32,7 +32,7 @@ from ...logging import get_logger
from ... import htclient
from ...lanuages import Lanuages
from ...languages import Languages
from . import BaseAuthService
@@ -91,7 +91,7 @@ class Plugin(BaseAuthService):
htclient.raise_not_200(response)
return True
except Exception:
get_logger().exception(Lanuages().gettext("Failed HTTP auth request for user %r"), user)
get_logger().exception(Languages().gettext("Failed HTTP auth request for user %r"), user)
return False
async def cleanup(self) -> None: