@posthog/react-native-plugin 2.3.0 → 2.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/android/src/main/java/com/posthogreactnativeplugin/PosthogReactNativePluginModule.kt
CHANGED
|
@@ -485,7 +485,7 @@ class PosthogReactNativePluginModule(
|
|
|
485
485
|
if (!config.capturePushNotificationOpened) {
|
|
486
486
|
return
|
|
487
487
|
}
|
|
488
|
-
val intent = currentActivity?.intent ?: return
|
|
488
|
+
val intent = reactApplicationContext.currentActivity?.intent ?: return
|
|
489
489
|
// A relaunch from recents redelivers the original tray intent to a fresh activity;
|
|
490
490
|
// capturing it would count a days-old tap as a new open.
|
|
491
491
|
if (intent.flags and Intent.FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY != 0) {
|