From 153144ace4629136ccfc4d3374c64afeca7f56cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20Baz=C3=A1n?= Date: Fri, 8 Jan 2016 17:11:28 -0300 Subject: [PATCH] fix copayer creator id error --- lib/pushnotificationsservice.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/pushnotificationsservice.js b/lib/pushnotificationsservice.js index 7237847..8b1c695 100644 --- a/lib/pushnotificationsservice.js +++ b/lib/pushnotificationsservice.js @@ -91,6 +91,8 @@ PushNotificationsService.prototype._sendPushNotifications = function(notificatio var notifType = PUSHNOTIFICATIONS_TYPES[notification.type]; if (!notifType) return cb(); + console.log(notification); + self._getRecipientsList(notification, function(err, recipientsList) { if (err) return cb(err); @@ -162,7 +164,7 @@ PushNotificationsService.prototype._getRecipientsList = function(notification, c })); var recipientsList = _.reject(self._join(wallet.copayers, recipients), { - id: notification.creatorId + copayerId: notification.creatorId }); return cb(null, recipientsList);