Skip to content

Commit

Permalink
Merge 490ceb1 into a160ed7
Browse files Browse the repository at this point in the history
  • Loading branch information
koriwi committed Aug 6, 2019
2 parents a160ed7 + 490ceb1 commit c5e1232
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/sendGCM.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ const sendGCM = (regIds, data, settings) => {
const GCMSender = new gcm.Sender(id, opts);
const promises = [];
const notification = {
id: data.id,
group: data.group,
title: data.title, // Android, iOS (Watch)
body: data.body, // Android, iOS
icon: data.icon, // Android
Expand Down Expand Up @@ -106,7 +108,8 @@ const sendGCM = (regIds, data, settings) => {
data: data.custom,
};
}

custom.id = custom.id || data.id;
custom.group = custom.group || data.group;
custom.title = custom.title || data.title;
custom.message = custom.message || data.body;
custom.sound = custom.sound || data.sound;
Expand Down

0 comments on commit c5e1232

Please sign in to comment.