Account for draft being published. Need to reload the collection still in this scenario

This commit is contained in:
Tom Moor
2018-05-07 22:53:13 -07:00
parent ba0a7b7f4a
commit 94e63b6171
2 changed files with 13 additions and 1 deletions

View File

@ -156,6 +156,9 @@ class Collection extends BaseModel {
}
}
);
this.on('documents.publish', (data: { collectionId: string }) => {
if (data.collectionId === this.id) this.fetch();
});
this.on('documents.move', (data: { collectionId: string }) => {
if (data.collectionId === this.id) this.fetch();
});