From cbb7e91eb4237a93d59a07c16b39b7c8409c677d Mon Sep 17 00:00:00 2001 From: Toby Zerner Date: Wed, 24 Jun 2015 11:45:58 +0930 Subject: [PATCH] Only display the first page of posts Extra posts may be in the payload (mention links etc.) but we do not want to display them. --- framework/core/js/forum/src/components/discussion-page.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/core/js/forum/src/components/discussion-page.js b/framework/core/js/forum/src/components/discussion-page.js index 25235430a..30f3be46a 100644 --- a/framework/core/js/forum/src/components/discussion-page.js +++ b/framework/core/js/forum/src/components/discussion-page.js @@ -97,7 +97,7 @@ export default class DiscussionPage extends mixin(Component, evented) { includedPosts.push(app.store.getById('posts', record.id)); } }); - includedPosts.sort((a, b) => a.id() - b.id()); + includedPosts.sort((a, b) => a.id() - b.id()).splice(20); } this.stream = new PostStream({ discussion, includedPosts });