Skip to content

Commit

Permalink
fix(iOS): adapt payload naming variables according to latest relase o…
Browse files Browse the repository at this point in the history
…f apns2 related to live activity
  • Loading branch information
Gonzalo Avilez authored and Gonzalo Avilez committed Aug 15, 2024
1 parent ba9ab3e commit 55d0b8b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions notify/notification_apns.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,23 +296,23 @@ func iosAlertDictionary(notificationPayload *payload.Payload, req *PushNotificat
}

if len(req.ContentState) > 0 {
notificationPayload.ContentState(req.ContentState)
notificationPayload.SetContentState(req.ContentState)
}

if req.StaleDate > 0 {
notificationPayload.StaleDate(req.StaleDate)
notificationPayload.SetStaleDate(req.StaleDate)
}

if req.DismissalDate > 0 {
notificationPayload.DismissalDate(req.DismissalDate)
notificationPayload.SetDismissalDate(req.DismissalDate)
}

if len(req.Event) > 0 {
notificationPayload.Event(req.Event)
notificationPayload.SetEvent(payload.ELiveActivityEvent(req.Event))
}

if req.Timestamp > 0 {
notificationPayload.Timestamp(req.Timestamp)
notificationPayload.SetTimestamp(req.Timestamp)
}

return notificationPayload
Expand Down

0 comments on commit 55d0b8b

Please sign in to comment.