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

Commit 9463c2f8 authored by Michael Chan's avatar Michael Chan
Browse files

b/2320107 NPE when receiving a Undock event without a device

Change-Id: Ic3c964f2d58462a1b7c82f2de2dd997679f90ba7
parent a87f2fd7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -131,7 +131,7 @@ public class BluetoothEventRedirector {
                int anythingButUnDocked = Intent.EXTRA_DOCK_STATE_UNDOCKED + 1;
                int state = intent.getIntExtra(Intent.EXTRA_DOCK_STATE, anythingButUnDocked);
                if (state == Intent.EXTRA_DOCK_STATE_UNDOCKED) {
                    if (device.getBondState() == BluetoothDevice.BOND_NONE) {
                    if (device != null && device.getBondState() == BluetoothDevice.BOND_NONE) {
                        mManager.getCachedDeviceManager().onDeviceDisappeared(device);
                    }
                }