matters-server
matters-server copied to clipboard
Backend filtering archived comments
Description
Currently, we do comment filtering in client-side with rules [1],
- For level-1 comments: hide archived if it hasn't level-2 non-archived comments;
- For level-2 comments: hide archived;
However, user might need to click more than one time if comments of next pages are all filtered out...
Tasks
- [x] Make sure API always returning the same size of result
- [ ] Return less info of archived comment
References
- https://github.com/thematters/matters-web/blob/98463d0ad5bb866ab3ddcf5b5435307d8bf1c30d/src/common/utils/comment.ts#L15
- https://feedback.matters.town/bug-reports/p/010f7a
- Discussion
- Discussion
prior fix PR only applied to Article.responses
, did not cover Article.comments