@dhyasama/totem-models 7.53.3 → 7.53.5
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/lib/Financials.js +5 -5
- package/package.json +1 -1
package/lib/Financials.js
CHANGED
|
@@ -299,8 +299,8 @@ module.exports = function(mongoose, config) {
|
|
|
299
299
|
});
|
|
300
300
|
|
|
301
301
|
var hasRecipients = snapshot.notifications.company.sendTo.length > 0;
|
|
302
|
-
var hasSendOnLessThanNow =
|
|
303
|
-
var hasNotBeenSentTo = !sendOnLessThanNow.sentOn;
|
|
302
|
+
var hasSendOnLessThanNow = sendOnLessThanNow;
|
|
303
|
+
var hasNotBeenSentTo = sendOnLessThanNow && !sendOnLessThanNow.sentOn;
|
|
304
304
|
|
|
305
305
|
return hasRecipients && hasSendOnLessThanNow && hasNotBeenSentTo;
|
|
306
306
|
|
|
@@ -342,8 +342,8 @@ module.exports = function(mongoose, config) {
|
|
|
342
342
|
});
|
|
343
343
|
|
|
344
344
|
var hasRecipients = snapshot.notifications.company.sendTo.length > 0;
|
|
345
|
-
var hasSendOnLessThanNow =
|
|
346
|
-
var hasNotBeenSentTo = !sendOnLessThanNow.sentOn;
|
|
345
|
+
var hasSendOnLessThanNow = sendOnLessThanNow;
|
|
346
|
+
var hasNotBeenSentTo = sendOnLessThanNow && !sendOnLessThanNow.sentOn;
|
|
347
347
|
|
|
348
348
|
return hasRecipients && hasSendOnLessThanNow && hasNotBeenSentTo;
|
|
349
349
|
|
|
@@ -492,7 +492,7 @@ module.exports = function(mongoose, config) {
|
|
|
492
492
|
snapshot.action = null;
|
|
493
493
|
}
|
|
494
494
|
|
|
495
|
-
else if(
|
|
495
|
+
else if(snapshot.notifications.company && snapshot.notifications.company.initial && snapshot.notifications.company.initial.sendOn) {
|
|
496
496
|
|
|
497
497
|
var latestReminder = _.max(snapshot.notifications.company.reminders, function(r) { return new Date(r.sendOn); });
|
|
498
498
|
|