fixed ingoring locale choice in the first message

This commit is contained in:
leca 2024-08-08 22:00:16 +03:00
parent 93f746a766
commit 21731dc0ae
1 changed files with 1 additions and 0 deletions

View File

@ -78,6 +78,7 @@ client.on("room.message", async (roomId, event) => {
if (a[0] !== "!start") return;
if (a[1] !== "ru" && a[1] !== "en") return;
await setUserLanguage(roomId, a[1]);
i18n.locale = a[1]
await setUserState(roomId, "country");
await client.sendText(roomId, i18n.t(["setup", "country"]));