diff --git a/nonebot_plugin_dialectlist/__init__.py b/nonebot_plugin_dialectlist/__init__.py index 4a937e1..becd63b 100644 --- a/nonebot_plugin_dialectlist/__init__.py +++ b/nonebot_plugin_dialectlist/__init__.py @@ -168,8 +168,8 @@ async def handle_message( if isinstance(event,GroupMessageEvent): if plugin_config.dialectlist_excluded_self: - bot_id:str = await bot.call_api('get_login_info') - plugin_config.dialectlist_excluded_people.append(bot_id) + bot_id = await bot.call_api('get_login_info') + plugin_config.dialectlist_excluded_people.append(str(bot_id["user_id"])) gids:List[str] = [str(event.group_id)] msg_list = await get_message_records( group_ids=gids, @@ -182,7 +182,7 @@ async def handle_message( elif isinstance(event, GuildMessageEvent): if plugin_config.dialectlist_excluded_self: bot_id = await bot.call_api('get_guild_service_profile') - plugin_config.dialectlist_excluded_people.append(bot_id) + plugin_config.dialectlist_excluded_people.append(str(bot_id["user_id"])) guild_ids:List[str] = await get_guild_all_channel(event.guild_id,bot=bot) msg_list = await get_message_records( group_ids=guild_ids, @@ -202,4 +202,4 @@ async def handle_message( await rankings.send(msg) await asyncio.sleep(1) #让图片先发出来 await rankings.finish(plugin_config.dialectlist_string_suffix_format.format(timeCost=time.time()-st-1)) - \ No newline at end of file +