You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Calling Onesignal.logout() shows error in console.
Error:
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'getIdentityModel')
at on.<anonymous> (OneSignalSDK.page.es6.js?v=160203:1:220768)
at Generator.next (<anonymous>)
at OneSignalSDK.page.es6.js?v=160203:1:267888
at new Promise (<anonymous>)
at o (OneSignalSDK.page.es6.js?v=160203:1:267633)
at on.logout (OneSignalSDK.page.es6.js?v=160203:1:220711)
at sn.<anonymous> (OneSignalSDK.page.es6.js?v=160203:1:226285)
at Generator.next (<anonymous>)
at OneSignalSDK.page.es6.js?v=160203:1:267888
at new Promise (<anonymous>)
This shows the following line fails: const e = sn.coreDirector.getIdentityModel();
I assume sn.coreDirector is undefined. Tracking this through the code a bit, it appears that coreDirector should be created when OneSignal.init(...) is called. In debugging, I added another init call to ensure it was invoked, and when I did I got an error saying init can only be run once, so I've confirmed init is being called before logout.
What happened?
Calling
Onesignal.logout()
shows error in console.Error:
This shows the following line fails:
const e = sn.coreDirector.getIdentityModel();
I assume
sn.coreDirector
is undefined. Tracking this through the code a bit, it appears thatcoreDirector
should be created whenOneSignal.init(...)
is called. In debugging, I added anotherinit
call to ensure it was invoked, and when I did I got an error saying init can only be run once, so I've confirmedinit
is being called beforelogout
.What browsers are you seeing the problem on?
Chrome (Chromium)
What operating system are you running?
macOS
Steps to reproduce?
In another section on page:
The text was updated successfully, but these errors were encountered: