@@ -17,7 +17,12 @@ if (Meteor.isClient) {
if (Meteor.isServer) {
Meteor.publish("tasks", function () {
- return Tasks.find();
+ return Tasks.find({
+ $or: [
+ { private: { $ne: true }},
+ { owner: this.userId }
+ ]
+ });
});
}