Merge pull request #79 from meatjam/nonebot2_voice_bug_fixed

fix(guess_voice): 修复了获取角色语音时,未排除空格分隔符的问题。
This commit is contained in:
惜月 2022-06-27 03:28:18 -05:00 committed by GitHub
commit 21bb1cd029
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -114,6 +114,7 @@ async def get_genshin_voice(bot: Bot, event: Union[GroupMessageEvent, PrivateMes
else: else:
language = '' language = ''
name = name.replace('', '') name = name.replace('', '')
name = name.strip()
await download_voice(bot, event) await download_voice(bot, event)
path = await get_random_voice(name, language) path = await get_random_voice(name, language)
if not path: if not path: