summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTreehugger Robot <treehugger-gerrit@google.com>2018-03-19 22:31:12 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2018-03-19 22:31:12 +0000
commit077dc7afcf9f2d5bacfcd5a048d6303ed73792f6 (patch)
treefa2dc3ce9af9e207186a5a04bf8417157f5008a6
parentd43f57edb0f0184221a876183e3e4f41efd2bc22 (diff)
parent6f80c367c2579fc6829fc68bed9b5c8d220709b6 (diff)
Merge "Check null for getPhoneAccount() in VoicemailChannelUtils"
-rw-r--r--java/com/android/dialer/notification/VoicemailChannelUtils.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/java/com/android/dialer/notification/VoicemailChannelUtils.java b/java/com/android/dialer/notification/VoicemailChannelUtils.java
index 374619ade..ddc0f773c 100644
--- a/java/com/android/dialer/notification/VoicemailChannelUtils.java
+++ b/java/com/android/dialer/notification/VoicemailChannelUtils.java
@@ -180,6 +180,9 @@ import java.util.Set;
@NonNull Context context, @NonNull PhoneAccountHandle handle) {
PhoneAccount phoneAccount =
context.getSystemService(TelecomManager.class).getPhoneAccount(handle);
+ if (phoneAccount == null) {
+ return;
+ }
NotificationChannel channel =
newChannel(context, getChannelIdForAccount(handle), phoneAccount.getLabel());
migrateVoicemailSoundSettings(context, channel, handle);