Skip to content

Commit

Permalink
fix: set limit on returned yeahed posts
Browse files Browse the repository at this point in the history
  • Loading branch information
CaramelKat committed Jul 29, 2024
1 parent fffd6c1 commit 8f66cf0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/services/juxt-web/routes/console/userpage.js
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ async function userRelations(req, res, userID) {
let followers; let communities; let communityMap; let selection;

if (req.params.type === 'yeahs') {
const posts = await POST.find({ yeahs: req.pid, removed: false }).sort({created_at: -1});
const posts = await POST.find({ yeahs: req.pid, removed: false }).sort({created_at: -1}).limit(config.post_limit);
/*let posts = await POST.aggregate([
{ $match: { id: { $in: likesArray } } },
{$addFields: {
Expand Down

0 comments on commit 8f66cf0

Please sign in to comment.