notifications.create can return null

This commit is contained in:
barisusakli
2016-01-27 20:03:28 +02:00
parent 19c7411c38
commit add4e6ee5b
6 changed files with 49 additions and 51 deletions

View File

@@ -90,7 +90,7 @@ var async = require('async'),
if (oldNotification) {
if (parseInt(oldNotification.pid, 10) === parseInt(data.pid, 10) && parseInt(oldNotification.importance, 10) > parseInt(data.importance, 10)) {
return callback();
return callback(null, null);
}
}
@@ -367,7 +367,7 @@ var async = require('async'),
return cur;
}, []);
differentiators.forEach(function(differentiator) {
set = isolated.filter(function(notifObj) {
return notifObj.mergeId === (mergeId + '|' + differentiator);