Switching stream to use action summaries function.

This commit is contained in:
David Jay
2016-11-08 15:23:04 -05:00
parent d3b8184ff4
commit fcd65c18fd
+1 -1
View File
@@ -14,7 +14,7 @@ router.get('/', (req, res, next) => {
return Promise.all([
comments,
User.findByIdArray(comments.map((comment) => comment.author_id)),
Action.findByItemIdArray(comments.map((comment) => comment.id))
Action.getActionSummaries(comments.map((comment) => comment.id))
]);
}).then(([comments, users, actions]) => {
res.json([...comments, ...users, ...actions]);