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

Commit a6a88a4e authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Use BluetoothUtils#getGroupId." into main

parents 7a262235 1864dfa9
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -631,15 +631,15 @@ public class BluetoothUtils {
                assistantProfile.getAllConnectedDevices().stream()
                        .map(deviceManager::findDevice)
                        .filter(Objects::nonNull)
                        .map(CachedBluetoothDevice::getGroupId)
                        .map(BluetoothUtils::getGroupId)
                        .collect(Collectors.toSet());
        Set<Integer> activeGroupIds =
                leAudioProfile.getActiveDevices().stream()
                        .map(deviceManager::findDevice)
                        .filter(Objects::nonNull)
                        .map(CachedBluetoothDevice::getGroupId)
                        .map(BluetoothUtils::getGroupId)
                        .collect(Collectors.toSet());
        int groupId = cachedDevice.getGroupId();
        int groupId = getGroupId(cachedDevice);
        return activeGroupIds.size() == 1
                && !activeGroupIds.contains(groupId)
                && connectedGroupIds.size() == 2