Verified Commit 68098ddf authored by Sébastiaan Versteeg's avatar Sébastiaan Versteeg
Browse files

Add notification title+body to message data

parent e2f8f12c
...@@ -149,11 +149,13 @@ class Message(models.Model, metaclass=ModelTranslateMeta): ...@@ -149,11 +149,13 @@ class Message(models.Model, metaclass=ModelTranslateMeta):
data = kwargs.get('data', {}) data = kwargs.get('data', {})
if self.url is not None: if self.url is not None:
data['url'] = self.url data['url'] = self.url
data['title'] = self.title
data['body'] = str(self.body)
message = messaging.Message( message = messaging.Message(
notification=messaging.Notification( notification=messaging.Notification(
title=self.title, title=data['title'],
body=str(self.body), body=data['body'],
), ),
data=data, data=data,
android=messaging.AndroidConfig( android=messaging.AndroidConfig(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment