Commit Graph
1 Commits
Author SHA1 Message Date
Sebastien Melki 5cb40cf5b4 [Important] allow sending data ONLY notifications for FCM notifi… (#453)
* allow sending data ONLY notifications for FCM notifications

ran into a little issue here need this tweak to be able to send and process background notifications on android

If you want to process android notifications in the BACKGROUND, they need to be data notifications, as in not contain the "notification" key in the payload.

This little change achieves it, because omitempty on structs for the JSON encoding does not work on sub-structs except if it is a pointer to it and set to nil.
Co-authored-by: Bo-Yi Wu <appleboy.tw@gmail.com>
2020-01-20 23:14:07 +08:00