react-onesignal icon indicating copy to clipboard operation
react-onesignal copied to clipboard

Fix missing reject for init

Open fehergeri13 opened this issue 1 year ago • 1 comments

When I init the oneSignal sdk with some invalid config, I get the following error:

try {
    await OneSignal.init({ appId: "example app id" });
} catch(e) {
    console.log("error with init")
}
Uncaught (in promise) Error: OneSignalSDK: HTTP sites are no longer supported starting with version 16 (User Model), your public site must start with https://. Please visit the OneSignal dashboard's Settings > Web Configuration to find this option.

This is an example error. The main issue is that the error is uncaught.

This PR will fix the uncaught exception

fehergeri13 avatar Mar 12 '24 13:03 fehergeri13

Thanks for opening the PR. I'll forward this to the team so they can review 🙏🏽

iAmWillShepherd avatar Aug 01 '24 14:08 iAmWillShepherd