Move every Checklists.find(idOrFirstObjectSelector, options) to the ReactiveCache (directory server/)

This commit is contained in:
Martin Filser 2023-03-12 18:07:50 +01:00
parent 06f0ceebd1
commit a4408b55ed
2 changed files with 11 additions and 7 deletions

View file

@ -54,13 +54,17 @@ Meteor.publish('notificationChecklistItems', function() {
// gets all checklists associated with activities associated with the current user
Meteor.publish('notificationChecklists', function() {
const ret = Checklists.find({
_id: {
$in: activities()
.map(v => v.checklistId)
.filter(v => !!v),
const ret = ReactiveCache.getChecklists(
{
_id: {
$in: activities()
.map(v => v.checklistId)
.filter(v => !!v),
},
},
});
{},
true,
);
return ret;
});