Closed vlinde closed 4 years ago
The issue you describe is likely specific to your project and not a bug with this plugin: this plugin provides a simple way to invoke the custom URL schemes installed on a device, therefore there is little code that can cause such a problem.
When you say "the launch button is not working anymore", it could be that an error in your app UI is causing the invocation of the plugin to fail.
I suggest placing a breakpoint on the call to the navigate()
function in the your app code using Safari Web Inspector so you can debug it when the button is pressed.
Als please build and run an app from the example project to see if you can reproduce the issue to rule out other causes within your own app project.
I tried the example project and is working as expected.
On my app, when the preferred app is not selected from the options, the navigate function will use common.APP.USER_SELECT
as value. Then the navigator app from the select list should be selected.
The app will be locked when the function getItem
is called with param choice
.
In the debugger the last called function is ensureStore
from
var getItem = function(key, callback){
ensureStore();
return store.getItem(key, function(err, value){
callback(value);
});
};
The execution is stopped because the return
is not reached and the callback is not executed.
I think the issue is related to the local storage.
Thanks for taking time to investigate. I will close this for now as it looks like you've found the problem and it's not related to this plugin.
Bug report
Current behavior: Sometimes the function call (
navigate
) is not opening the navigator map.Expected behavior: The button must work every time.
Steps to reproduce: The button (the function call) is working as expected for a while but if I open a navigation app, I do some things and when I come back to my app, the launch button is not working anymore. Sometimes I can open the navigation app for many times but after my app runs in the background for a little bit longer, the button will not work as expected. My app is not crashed or something like that, it will work as expected, only the launch button is not responding.
Environment information
Cordova CLI version
8.1.2 (cordova-lib@8.1.1)
Cordova platform version
android 8.1.0
ios 5.1.1
Dev machine OS and version, e.g.
Mac OS X 10.15.1
OS details
iOS 13.x
iOS build issue:
v11.11.0
11.2.1
Related code:
I checked the project vars and they are ok every time. Console output
Other information: I tried to set the
launchNavigatorOptions
var when I press the button or when I open the page. On both cases I have the same issue. I checked the logs from xCode, the function is triggered, I can see some messages (my phone doesn't have all navigation apps installed. I get these messages in all cases, when it's working or not) but I can't see any error.