From 0b9a8cd9c833215893656a059963dbfb1c826fba Mon Sep 17 00:00:00 2001 From: Hojjat Date: Fri, 20 Mar 2026 11:01:58 -0600 Subject: [PATCH] fix(bluetooth): call connect() after pair() for unpaired devices Calling pair() works for keyboards since they do a PIN confirmation afterward and connect later. For headphones we can connect right away. Calling pair and connect works for both. --- subscriptions/bluetooth/src/device.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/subscriptions/bluetooth/src/device.rs b/subscriptions/bluetooth/src/device.rs index e8777c0..aec4a72 100644 --- a/subscriptions/bluetooth/src/device.rs +++ b/subscriptions/bluetooth/src/device.rs @@ -241,7 +241,8 @@ pub async fn connect_device(connection: zbus::Connection, device_path: OwnedObje if proxy.device.connected().await? { Ok(()) } else if !proxy.device.paired().await.unwrap_or(false) { - proxy.device.pair().await + proxy.device.pair().await?; + proxy.device.connect().await } else { proxy.device.connect().await }