mirror of
https://github.com/SimpleMobileTools/Simple-Dialer.git
synced 2025-02-19 04:50:53 +01:00
Catch all exceptions
This commit is contained in:
parent
129d9e9f66
commit
811350a1be
@ -1,7 +1,6 @@
|
||||
package com.simplemobiletools.dialer.services
|
||||
|
||||
import android.app.KeyguardManager
|
||||
import android.content.ActivityNotFoundException
|
||||
import android.content.Context
|
||||
import android.telecom.Call
|
||||
import android.telecom.InCallService
|
||||
@ -36,8 +35,8 @@ class CallService : InCallService() {
|
||||
try {
|
||||
callNotificationManager.setupNotification(true)
|
||||
startActivity(CallActivity.getStartIntent(this))
|
||||
} catch (e: ActivityNotFoundException) {
|
||||
// seems like startActivity can thrown AndroidRuntimeException and ActivityNotFoundException, not yet sure when and why, lets show a notification
|
||||
} catch (e: Exception) {
|
||||
// seems like startActivity can throw AndroidRuntimeException and ActivityNotFoundException, not yet sure when and why, lets show a notification
|
||||
callNotificationManager.setupNotification()
|
||||
}
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user