hypery2k / cordova-email-plugin

Edit and send email messages
Apache License 2.0
44 stars 29 forks source link

iOS: isAvailable is true when default Mail app is not installed #41

Open pavlo-liapin opened 7 years ago

pavlo-liapin commented 7 years ago

iOS 10.2 Cordova 6.4.0

When default Mail app is uninstalled on iOS, system shows the attached screen, and isAvailable is immediately resolved to true. So when user clicks Cancel, cordova.plugins.email.open fails to launch any apps.

restore

--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/40897910-ios-isavailable-is-true-when-default-mail-app-is-not-installed?utm_campaign=plugin&utm_content=tracker%2F12875371&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F12875371&utm_medium=issues&utm_source=github).
hypery2k commented 7 years ago

so what would your desired behaviour?

pavlo-liapin commented 7 years ago

If it is possible to detect this scenario on iOS, isAvailable has to be false in this case, because email.open simply fails silently.

hypery2k commented 7 years ago

maybe the canOpenURL could help to add this feature.