diff options
Diffstat (limited to 'src/com/android/dialer')
-rw-r--r-- | src/com/android/dialer/util/TelecomUtil.java | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/com/android/dialer/util/TelecomUtil.java b/src/com/android/dialer/util/TelecomUtil.java index bd201c459..69c7334b9 100644 --- a/src/com/android/dialer/util/TelecomUtil.java +++ b/src/com/android/dialer/util/TelecomUtil.java @@ -95,11 +95,14 @@ public class TelecomUtil { } public static boolean handleMmi(Context context, String dialString, - PhoneAccountHandle handle) { + @Nullable PhoneAccountHandle handle) { if (hasModifyPhoneStatePermission(context)) { try { - return TelecomManagerCompat.handleMmi( - getTelecomManager(context), dialString, handle); + if (handle == null) { + return getTelecomManager(context).handleMmi(dialString); + } else { + return getTelecomManager(context).handleMmi(dialString, handle); + } } catch (SecurityException e) { Log.w(TAG, "TelecomManager.handleMmi called without permission."); } |