1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-12-30 12:35:48 +01:00

Avoid potential NPE

This commit is contained in:
cpfeiffer 2018-08-06 19:54:33 +02:00
parent 88714ece4d
commit f7c9828cc1

View File

@ -151,7 +151,7 @@ public class HuamiSupport extends AbstractBTLEDeviceSupport {
@Override @Override
public void onReceive(Context context, Intent intent) { public void onReceive(Context context, Intent intent) {
String s = intent.getAction(); String s = intent.getAction();
if (s.equals(DeviceInfoProfile.ACTION_DEVICE_INFO)) { if (DeviceInfoProfile.ACTION_DEVICE_INFO.equals(s)) {
handleDeviceInfo((nodomain.freeyourgadget.gadgetbridge.service.btle.profiles.deviceinfo.DeviceInfo) intent.getParcelableExtra(DeviceInfoProfile.EXTRA_DEVICE_INFO)); handleDeviceInfo((nodomain.freeyourgadget.gadgetbridge.service.btle.profiles.deviceinfo.DeviceInfo) intent.getParcelableExtra(DeviceInfoProfile.EXTRA_DEVICE_INFO));
} }
} }