[CDM Perm Sync] Fix a NPE for Perm Sync toggle am: 8c51d9c71d am: cf705cf873
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/24790419 Change-Id: I10fccd7b4036a57cdb665eb22a79b600fb006898 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -64,6 +64,7 @@ public class BluetoothDetailsDataSyncController extends BluetoothDetailsControll
|
|||||||
mCompanionDeviceManager = context.getSystemService(CompanionDeviceManager.class);
|
mCompanionDeviceManager = context.getSystemService(CompanionDeviceManager.class);
|
||||||
|
|
||||||
mCompanionDeviceManager.getAllAssociations().stream().filter(
|
mCompanionDeviceManager.getAllAssociations().stream().filter(
|
||||||
|
a -> a.getDeviceMacAddress() != null).filter(
|
||||||
a -> Objects.equal(mCachedDevice.getAddress(),
|
a -> Objects.equal(mCachedDevice.getAddress(),
|
||||||
a.getDeviceMacAddress().toString().toUpperCase())).max(
|
a.getDeviceMacAddress().toString().toUpperCase())).max(
|
||||||
Comparator.comparingLong(AssociationInfo::getTimeApprovedMs)).ifPresent(
|
Comparator.comparingLong(AssociationInfo::getTimeApprovedMs)).ifPresent(
|
||||||
|
|||||||
Reference in New Issue
Block a user