From 99b95dfd608a5959bc0f88a9970667d6315826ea Mon Sep 17 00:00:00 2001 From: Bakadax Date: Sun, 4 May 2025 19:02:09 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=87=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/config/config.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/config/config.py b/src/config/config.py index 98427912..39e346c7 100644 --- a/src/config/config.py +++ b/src/config/config.py @@ -372,9 +372,10 @@ class BotConfig: def personality(parent: dict): personality_config = parent["personality"] - if config.INNER_VERSION in SpecifierSet(">=1.6.1.2"): + if config.INNER_VERSION in SpecifierSet(">=1.2.4"): config.personality_core = personality_config.get("personality_core", config.personality_core) config.personality_sides = personality_config.get("personality_sides", config.personality_sides) + if config.INNER_VERSION in SpecifierSet(">=1.6.1.2"): config.personality_detail_level = personality_config.get("personality_detail_level", config.personality_sides) def identity(parent: dict): @@ -461,6 +462,8 @@ class BotConfig: config.ban_words = chat_config.get("ban_words", config.ban_words) for r in chat_config.get("ban_msgs_regex", config.ban_msgs_regex): config.ban_msgs_regex.add(re.compile(r)) + if config.INNER_VERSION in SpecifierSet(">=1.6.1.2"): + config.allow_remove_duplicates = chat_config.get("allow_remove_duplicates", config.allow_remove_duplicates) def normal_chat(parent: dict): normal_chat_config = parent["normal_chat"]