Loading presentation/src/main/java/com/moez/QKSMS/common/Navigator.kt +3 −8 Original line number Diff line number Diff line Loading @@ -237,14 +237,9 @@ class Navigator @Inject constructor( } fun addContact(address: String) { val uri = Uri.parse("tel: $address") var intent = Intent(ContactsContract.Intents.SHOW_OR_CREATE_CONTACT, uri) if (intent.resolveActivity(context.packageManager) == null) { intent = Intent(Intent.ACTION_INSERT) val intent = Intent(Intent.ACTION_INSERT) .setType(ContactsContract.Contacts.CONTENT_TYPE) .putExtra(ContactsContract.Intents.Insert.PHONE, address) } startActivityExternal(intent) } Loading Loading
presentation/src/main/java/com/moez/QKSMS/common/Navigator.kt +3 −8 Original line number Diff line number Diff line Loading @@ -237,14 +237,9 @@ class Navigator @Inject constructor( } fun addContact(address: String) { val uri = Uri.parse("tel: $address") var intent = Intent(ContactsContract.Intents.SHOW_OR_CREATE_CONTACT, uri) if (intent.resolveActivity(context.packageManager) == null) { intent = Intent(Intent.ACTION_INSERT) val intent = Intent(Intent.ACTION_INSERT) .setType(ContactsContract.Contacts.CONTENT_TYPE) .putExtra(ContactsContract.Intents.Insert.PHONE, address) } startActivityExternal(intent) } Loading