diff --git a/src/libbot/matrix/classes/bot.py b/src/libbot/matrix/classes/bot.py index 85d79f7..512097f 100644 --- a/src/libbot/matrix/classes/bot.py +++ b/src/libbot/matrix/classes/bot.py @@ -5,6 +5,7 @@ from typing import Dict, Any from typing_extensions import override +from ... import __version__ as __libbot_version__ from ...i18n.classes import BotLocale from ...utils import json_read @@ -39,12 +40,20 @@ class MatrixBot(Bot): homeserver=self.bot_config["bot"]["homeserver"], username=self.bot_config["bot"]["username"], password=self.bot_config["bot"]["password"], - device_name=self.bot_config["bot"]["device_name"], + device_name=( + f"LibBotUniversal v{__libbot_version__}" + if "device_name" not in self.bot_config["bot"] + else self.bot_config["bot"]["device_name"] + ), ) ), config=smbl_config, ) + self.bot_prefix: str = ( + "!" if "prefix" not in self.bot_config["bot"] else self.bot_config["bot"]["prefix"] + ) + self.bot_locale: BotLocale = BotLocale( default_locale=self.bot_config["locale"], locales_root=(Path("locale") if locales_root is None else locales_root),