Skip to content

Commit

Permalink
Merge pull request #1 from llluis/fix-played-event
Browse files Browse the repository at this point in the history
bugfix played event
  • Loading branch information
llluis authored Feb 8, 2024
2 parents 1d86448 + 8a5f3fb commit c0e1b50
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion wyoming_satellite/satellite.py
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,8 @@ async def _disconnect() -> None:
event.type
):
await _disconnect()
await self.trigger_played()
if not hasattr(event, 'wav'):
await self.trigger_played()
snd_client = None # reconnect on next event
except asyncio.CancelledError:
break
Expand Down Expand Up @@ -604,6 +605,7 @@ async def _play_wav(
samples_per_chunk=self.settings.snd.samples_per_chunk,
volume_multiplier=self.settings.snd.volume_multiplier,
):
event.wav = True
await self.event_to_snd(event)
except Exception:
# Unmute in case of an error
Expand Down

0 comments on commit c0e1b50

Please sign in to comment.