Description:
In my app I use OneSignal's setEmail, at logout the logoutEmail function does not work. Even after calling her, I still receive notifications directed to the registered email
Environment
node: 10.16.3
yarn: 1.22.4
react-native: 0.60.4
react-native-onesignal: 3.7.3
Steps to Reproduce Issue:
After successful configuration of OneSignal, setEmail at login
(crash stacktraces, as well as any other information here)
Howdy,
Thank you for letting us know. We will look into this issue.
In the meantime, an alternative is you can set and unset the email as a tag.
Duplicate of https://github.com/OneSignal/OneSignal-Flutter-SDK/issues/239
To clarify, are you seeing this issue in Android or iOS or both? @marcoskoch
Thanks
Hi @rgomezp, this situation occurs in both
For visibility, I tested this using the RNOneSignal example app with the following metro bundler logs:
LOG Running "RNOneSignal" with {"rootTag":11,"initialProps":{}}
LOG Mounted!
LOG OneSignal permission: true
LOG Attempting to set email: [email protected]
LOG OneSignal: email subscription changed: {"emailAddress": "[email protected]", "emailUserId": "336b180d-7e87-4c77-87cc-d0c3f3fa7737"}
LOG Success setting email: [email protected]
LOG Attempting to set external user id: ro2
LOG Results of setting external user id
LOG {"email": {"success": 1}, "push": {"success": 1}}
LOG Attempting to logout email
LOG OneSignal: email subscription changed: {"emailAddress": null, "emailUserId": null}
In the dashboard, I see the following:

I haven't tested targeting the email after, but at least I can confirm there is currently no visible change occurring in the dashboard following calling the logoutEmail function.
Howdy y'all,
This issue should now be resolved. If you are still encountering issues, please continue discussion in https://github.com/OneSignal/OneSignal-iOS-SDK/issues/768
Enjoy!