From 41491981c1c82d2f0b8ea66df148f878a0795644 Mon Sep 17 00:00:00 2001 From: Yash Garg Date: Thu, 2 Jul 2026 20:40:08 +0530 Subject: [PATCH] fix: allow selectAudioOutput on Android flutter_webrtc's Helper.selectAudioOutput already routes audio on Android via device ID strings (speaker, earpiece, bluetooth, wired-headset). The desktop-only gate was silently swallowing the call and leaving room.setAudioOutputDevice() as a no-op on Android. --- lib/src/hardware/hardware.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/src/hardware/hardware.dart b/lib/src/hardware/hardware.dart index 6f75f94d1..ad8148b2e 100644 --- a/lib/src/hardware/hardware.dart +++ b/lib/src/hardware/hardware.dart @@ -119,8 +119,8 @@ class Hardware { } Future selectAudioOutput(MediaDevice device) async { - if (!lkPlatformIsDesktop()) { - logger.warning('selectAudioOutput is only supported on Desktop'); + if (lkPlatformIs(PlatformType.web) || lkPlatformIs(PlatformType.iOS)) { + logger.warning('selectAudioOutput is not supported on Web or iOS'); return; } selectedAudioOutput = device;