diff --git a/relay.py b/relay.py index 018b6c4..eee5cf7 100644 --- a/relay.py +++ b/relay.py @@ -237,7 +237,7 @@ class Relay: async def _on_speaker_frame(self, pcm_bytes): """Receive speaker PCM from bridge, resample, encode Opus, send to ESP32.""" - if not self.ws or self.ws.closed: + if not self.ws or getattr(self.ws, 'closed', False): return try: self._audio_out_count += 1