@optimiser/common 1.0.368 → 1.0.369
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/event.js +4 -1
- package/package.json +1 -1
package/dist/lib/event.js
CHANGED
|
@@ -92,10 +92,12 @@ var Event = /** @class */ (function () {
|
|
|
92
92
|
else {
|
|
93
93
|
delete data.PushNotificationObj;
|
|
94
94
|
}
|
|
95
|
+
console.log("notificationDataObj Before calling fcm send--------", notificationDataObj);
|
|
95
96
|
if (!this.FCMMobileServiceAccountKey) return [3 /*break*/, 7];
|
|
96
97
|
return [4 /*yield*/, db.collection('UserMobileNotification').findOne({ UserID: new mongodb_1.ObjectId(userId) })];
|
|
97
98
|
case 2:
|
|
98
99
|
userDeviceInfoObj = _a.sent();
|
|
100
|
+
console.log("userDeviceInfoObj", userDeviceInfoObj);
|
|
99
101
|
if (!(userDeviceInfoObj && userDeviceInfoObj.deviceToken && notificationDataObj)) return [3 /*break*/, 6];
|
|
100
102
|
message = {
|
|
101
103
|
token: userDeviceInfoObj.deviceToken,
|
|
@@ -119,7 +121,8 @@ var Event = /** @class */ (function () {
|
|
|
119
121
|
},
|
|
120
122
|
data: JSON.stringify(notificationDataObj) // changes done by komal, to get data attr val in notification
|
|
121
123
|
};
|
|
122
|
-
console.log("
|
|
124
|
+
console.log("FCM message payload------>", message);
|
|
125
|
+
console.log("notificationDataObj inside if condition------>", JSON.stringify(notificationDataObj));
|
|
123
126
|
_a.label = 3;
|
|
124
127
|
case 3:
|
|
125
128
|
_a.trys.push([3, 5, , 6]);
|