pwlin / cordova-plugin-file-opener2

A File Opener Plugin for Cordova
MIT License
314 stars 587 forks source link

Fix problem with errors not throwing the error callback in windows. #235

Closed Eeems closed 5 years ago

Eeems commented 5 years ago

Had to create a new PR for #52 as I had deleted the fork where the original PR came from. From the original PR:

On windows when attempting to open pdf files Windows.System.Launcher.launchFileAsync() is throwing the following error: "The parameter is incorrect" This error is not running the callback error due to not being caught by the promise handler. Adding a try/catch will solve this and at least allow the error to bubble up to the users code and allow them to debug it easier. Should at least help with #51 but not fix it.

shnist commented 5 years ago

@Eeems thanks for doing this.