修复自动播放的问题
This commit is contained in:
parent
e0a59b5729
commit
82eab4810c
@ -269,6 +269,8 @@ class XiaoMusic:
|
|||||||
await self.mina_service.text_to_speech(self.device_id, value)
|
await self.mina_service.text_to_speech(self.device_id, value)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
self.log.error(f"Execption {e}")
|
self.log.error(f"Execption {e}")
|
||||||
|
|
||||||
|
self.log.debug(f"do_tts. cur_music:{self.cur_music}")
|
||||||
if self._playing and not self.is_downloading():
|
if self._playing and not self.is_downloading():
|
||||||
# 继续播放歌曲
|
# 继续播放歌曲
|
||||||
await self.play()
|
await self.play()
|
||||||
@ -617,7 +619,7 @@ class XiaoMusic:
|
|||||||
return True
|
return True
|
||||||
else:
|
else:
|
||||||
# 当前播放的歌曲不存在了
|
# 当前播放的歌曲不存在了
|
||||||
if self.is_music_exist(self.cur_music):
|
if not self.is_music_exist(self.cur_music):
|
||||||
return True
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user