-
Notifications
You must be signed in to change notification settings - Fork 368
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
3.2.10: RNOneSignal.didSetNotificationOpenedHandler is not a function #682
Comments
Haha you beat me to it @wkoutre . The issue here is that, that function exists in the android module but not in the ios module. |
@prog-24 Glad to see it's not an infamous byproduct of my morning fatigue :) I looked into the Obj-C code a bit and didn't find any trace of it there, though haven't diffed the Obj-C code of |
• A new bridge function (didSetNotificationOpenedHandler) was recently added to the Android native implementation of the SDK, but a corresponding iOS implementation was not added • Fixes #682
Apologies about that, I didn't sleep at a Holiday Inn Express last night and forgot to add a method stub to iOS. We've changed how the Opened/Received event handlers work in our Android implementation. I've released an update (3.2.11) to fix the issue, thanks for reporting this so quickly! |
Is this officially resolved? I seem to still have the issue with iOS when I have "OneSignal.addEventListener('opened', this.onOpened);" I get "RNOneSignal.didSetNotificationOpenedHandler is not a function" |
@tehwayne yes the issue is definitely resolved, please make sure you’re running the latest version (3.2.12) |
@Nightsd01 thanks for the quick response! Does it have a requirement for react/react-native versioning? I'm running 3.2.12 with React 16.6 and RN 0.56., I've tried rolling backwards and have issues with that function all the way back to 3.2.6 (anything newer throws error). Seems it's possibly something on my side then, just want to check and see if there was anything I'm obviously missing, thanks! |
have you managed to solve this issue ?
|
Why this issue closed? I have same issue on Android with latest version 3.3.2 :( |
I have same issue on Android with latest version 3.3.2 ```
|
Same here, I have this issue in August 2019. |
Same here, |
Same issue |
Same issue |
Same issue |
Same issue |
same issue |
Hi all, |
I'm on the latest version and seem to be getting this every time I restart the packaging server (node start).
|
Any update on the issue? I am running react-native-onesignal 3.6.0 and am still experiencing the same issue @rgomezp |
I do not know if I fixed it right but I added the following lines to RCTOneSignalEventEmitter.m at line 360 and it works now @rgomezp
|
Hello, |
@rgomezp Will you be including this bug fix in the next release? |
Hi, I'm having this issue on Android on the latest version, 3.6.2 |
Make sure to run |
Hey @Rodrigo77777 , ps. Nice name! |
Still getting this error in the latest version (Android on Windows 10) and having to use this fix. Interestingly, it stopped on one project and popped up on a new one. |
Crucially - it's occurring (and the fix does not work) when attempting to build for release on Android, meaning we can't go to production. Any updates or fixes? @Nightsd01 @sidd65 @rgomezp
|
I've been having the same issue, did you find any solutions? |
This is for the ones still strugling on Android. It seems like the mentioned versions only fixed it for iOS. In order to make it work for Android, I had to open the class RNOneSignal.java and add the following method: @ReactMethod
public boolean didSetNotificationOpenedHandler() {
return this.hasSetNotificationOpenedHandler;
} Don't forget that Then I ran |
Description:
RNOneSignal.didSetNotificationOpenedHandler is not a function
(your description here)
Environment
(recently updated to
react-native-onesignal@3.2.10
fromreact-native-onesignal@3.2.8
:3.2.8
worked fine)Steps to Reproduce Issue:
// OneSignal.addEventListener("opened", this.onOpened);
DOES result in the error mentioned in the description.Anything else:
Indeed, when logging out
RNOnesignal
in the project'sindex.js
,didSetNotificationOpenedHandler
is not one of the included methods:The text was updated successfully, but these errors were encountered: