Skip to content

Commit 34fe4a3

Browse files
committed
Track event when viewing an in-app notification.
1 parent e59195d commit 34fe4a3

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

WooCommerce/Classes/Analytics/WooAnalyticsStat.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,7 @@ public enum WooAnalyticsStat: String {
288288
case pushNotificationOSAlertAllowed = "push_notification_os_alert_allowed"
289289
case pushNotificationOSAlertDenied = "push_notification_os_alert_denied"
290290
case pushNotificationOSAlertShown = "push_notification_os_alert_shown"
291+
case viewInAppPushNotificationPressed = "view_in_app_push_notification_pressed"
291292

292293
// MARK: Notification View Events
293294
//

WooCommerce/Classes/Notifications/PushNotificationsManager.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -371,6 +371,7 @@ private extension PushNotificationsManager {
371371
guard let self = self else { return }
372372
self.presentDetails(for: foregroundNotification)
373373
self.foregroundNotificationsToViewSubject.send(foregroundNotification)
374+
ServiceLocator.analytics.track(.viewInAppPushNotificationPressed)
374375
}
375376

376377
foregroundNotificationsSubject.send(foregroundNotification)

0 commit comments

Comments
 (0)