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

Commit d30c00eb authored by Yiyi Shen's avatar Yiyi Shen Committed by Android (Google) Code Review
Browse files

Merge "[Audiosharing] Fix get main device for LEA device w/o CSIP" into main

parents a1c29b99 fbad58a7
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1217,12 +1217,13 @@ public class LocalBluetoothLeBroadcast implements LocalBluetoothProfile {
                }
            }
        }
        Log.d(TAG, "updateFallbackActiveDeviceIfNeeded, earliest group id = " + targetGroupId);
        return targetGroupId;
    }

    @Nullable
    private CachedBluetoothDevice getMainDevice(@Nullable List<BluetoothDevice> devices) {
        if (devices == null || devices.size() == 1) return null;
        if (devices == null || devices.isEmpty()) return null;
        List<CachedBluetoothDevice> cachedDevices =
                devices.stream()
                        .map(device -> mDeviceManager.findDevice(device))