diff options
-rw-r--r-- | models/swimlanes.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/models/swimlanes.js b/models/swimlanes.js index 1b18ba5d..9da4afb5 100644 --- a/models/swimlanes.js +++ b/models/swimlanes.js @@ -133,14 +133,14 @@ Swimlanes.helpers({ }, lists() { - return Lists.find(Filter.mongoSelector({ + return Lists.find({ boardId: this.boardId, swimlaneId: {$in: [this._id, '']}, archived: false, - }), { sort: ['sort'] }); + }, { sort: ['sort'] }); }, - allLists() { + myLists() { return Lists.find({ swimlaneId: this._id }); }, @@ -189,7 +189,7 @@ Swimlanes.mutations({ archive() { if (this.isTemplateSwimlane()) { - this.lists().forEach((list) => { + this.myLists().forEach((list) => { return list.archive(); }); } @@ -198,7 +198,7 @@ Swimlanes.mutations({ restore() { if (this.isTemplateSwimlane()) { - this.allLists().forEach((list) => { + this.myLists().forEach((list) => { return list.restore(); }); } |