prevent activityNotFound crash on calendar intent
This commit is contained in:
parent
d5e12c4d88
commit
643ac62788
|
@ -174,8 +174,11 @@ public class MainActivity extends AppCompatActivity {
|
|||
// prepend url in description
|
||||
String desc = event.url + "\n\n" + event.description;
|
||||
intent.putExtra(CalendarContract.Events.DESCRIPTION, desc);
|
||||
|
||||
if (intent.resolveActivity(getPackageManager()) != null) {
|
||||
startActivity(intent);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue