When using native.popup, how to check if email account is already configured?

I try to use this,

native.showPopup("mail", options)

to pop up the email client for sharing something.

It works fine, however if the user does not have Email account configured, 

“nothing happens”

There is no email popup because there is no email account & there is no system alert either.

It’s kind of weird and I want to show some message to let the user know that he/she has to configure email account in order to share by email.

I put a listener for the popup in the option,

local function popupListener(event) local k,v for k,v in pairs(event) do print("k/v=", k, v) end end

This listener is not called in this case either.

Is it possible to know if the user has email configured in order to show alert in this case?

I’ve found the answer,

it’s easy to know actually,

native.showPopup(“mail”, options) will return false

if no email account is configured!

I’ve found the answer,

it’s easy to know actually,

native.showPopup(“mail”, options) will return false

if no email account is configured!