If you have recently updated the pushwoosh-react-native-plugin to version 6.7.33 and are encountering an Android build error, this is a known issue that has been resolved in subsequent releases.
The error message typically looks like this:
'onMessageReceived(PushMessage)' in 'com.pushwoosh.reactnativeplugin.PushwooshNotificationServiceExtension' clashes with 'onMessageReceived(PushMessage)' in 'com.pushwoosh.notification.NotificationServiceExtension'; attempting to assign weaker access privileges ('protected'); was 'public'
This error was caused by a method visibility mismatch between the React Native plugin and the native Android SDK in that specific version. The same issue could also affect the startActivityForPushMessage and onMessageOpened methods.
Resolution
To fix this, please update the pushwoosh-react-native-plugin in your project to the latest available version.
- Modify your
package.jsonto use the latest version of@pushwoosh/react-native-plugin. - Delete your
node_modulesfolder and thepackage-lock.jsonoryarn.lockfile. - Run
npm installoryarn installto download the updated version. - Rebuild your Android application.
Comments
0 comments
Please sign in to leave a comment.