Skip to content

Commit

Permalink
Move code around to try and fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
synesthesiam committed Sep 9, 2024
1 parent 420a96e commit 30a97ac
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions aioesphomeapi/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1373,13 +1373,14 @@ def _on_voice_assistant_audio(msg: VoiceAssistantAudio) -> None:
)
)

def _on_voice_assistant_announcement_finished(
msg: VoiceAssistantAnnounceFinished,
) -> None:
finished = VoiceAssistantAnnounceFinishedModel.from_pb(msg)
self._create_background_task(handle_announcement_finished(finished))

if handle_announcement_finished is not None:

def _on_voice_assistant_announcement_finished(
msg: VoiceAssistantAnnounceFinished,
) -> None:
finished = VoiceAssistantAnnounceFinishedModel.from_pb(msg)
self._create_background_task(handle_announcement_finished(finished))

remove_callbacks.append(
connection.add_message_callback(
_on_voice_assistant_announcement_finished,
Expand Down

0 comments on commit 30a97ac

Please sign in to comment.