Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 67a6c7ea authored by John Lai's avatar John Lai Committed by Automerger Merge Worker
Browse files

Merge "floss: pandora: fix host.Connect" into main am: 59021f1c am: 17537f42

parents a029d31f 17537f42
Loading
Loading
Loading
Loading
+18 −19
Original line number Diff line number Diff line
@@ -130,9 +130,6 @@ class HostService(host_grpc_aio.HostServicer):

            @utils.glib_callback()
            def on_ssp_request(self, remote_device, class_of_device, variant, passkey):
                if self.security.manually_confirm:
                    return

                address, _ = remote_device
                if address != self.task['address']:
                    return
@@ -170,6 +167,7 @@ class HostService(host_grpc_aio.HostServicer):
                    if not success:
                        raise RuntimeError(f'Failed to connect to the {address}. Reason: {reason}')
                else:
                    if not self.security.manually_confirm:
                        create_bond = asyncio.get_running_loop().create_future()
                        observer = PairingObserver(
                            self.bluetooth.adapter_client,
@@ -185,6 +183,7 @@ class HostService(host_grpc_aio.HostServicer):
                    if not self.bluetooth.create_bond(address, floss_enums.BtTransport.BREDR):
                        raise RuntimeError('Failed to call create_bond.')

                    if not self.security.manually_confirm:
                        success, reason = await create_bond

                        if not success: