diff --git a/app/src/main/java/io/github/wulkanowy/utils/ContextExtension.kt b/app/src/main/java/io/github/wulkanowy/utils/ContextExtension.kt index 68d3afe8..2cd4459e 100644 --- a/app/src/main/java/io/github/wulkanowy/utils/ContextExtension.kt +++ b/app/src/main/java/io/github/wulkanowy/utils/ContextExtension.kt @@ -102,7 +102,9 @@ fun Context.openNavigation(location: String) { fun Context.openDialer(phone: String) { val intentUri = Uri.parse("tel:$phone") val intent = Intent(Intent.ACTION_DIAL, intentUri) - startActivity(intent) + if (intent.resolveActivity(packageManager) != null) { + startActivity(intent) + } } fun Context.shareText(text: String, subject: String?) {