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

Commit 98947a79 authored by Yuyang Huang's avatar Yuyang Huang Committed by Automerger Merge Worker
Browse files

Merge "Skip mAudioManager callback if it is null" am: edbc8dd7 am: e536a797

parents 5cdf7397 e536a797
Loading
Loading
Loading
Loading
+10 −2
Original line number Diff line number Diff line
@@ -748,7 +748,11 @@ public class HearingAidService extends ProfileService {
                    if (DBG) {
                        Log.d(TAG, " onAudioDevicesRemoved: device type: " + deviceInfo.getType());
                    }
                    if (mAudioManager != null) {
                        mAudioManager.unregisterAudioDeviceCallback(this);
                    } else {
                        Log.w(TAG, "onAudioDevicesRemoved: mAudioManager is null");
                    }
                }
            }
        }
@@ -764,7 +768,11 @@ public class HearingAidService extends ProfileService {
                    if (DBG) {
                        Log.d(TAG, " onAudioDevicesAdded: device type: " + deviceInfo.getType());
                    }
                    if (mAudioManager != null) {
                        mAudioManager.unregisterAudioDeviceCallback(this);
                    } else {
                        Log.w(TAG, "onAudioDevicesAdded: mAudioManager is null");
                    }
                }
            }
        }