Starting today, post authors and site admins have the ability to lock discussions on posts to prevent comments from being added.
This feature is designed for both user safety and to allow authors the ability to manage the conversations happening under their own post.
It's our hope that providing authors and admins the ability to lock discussions will help relieve instances where "piling on" occurs in the comments section — e.g. think of those times where you've seen someone criticize an author for X and then lots of other folks comment inline to agree with and restate the criticism. Criticism isn't inherently bad of course, but when criticism is particularly biting and lots of people are joining in to repeat it, it can be excessive and unnecessarily hurtful. It can often set a pretty terrible tone and misplace the focus. We think it's totally reasonable for an author to lock a discussion when this happens.
We also believe this feature will be helpful to authors who want to post something particularly sensitive and would prefer for there not to be a discussion on the topic at all. We can definitely empathize with this decision and want to give authors that option.
We understand that it's possible a user might try to wield this ability to shield themselves from criticism. It is definitely not our intention to give authors a free pass to write anything they please without reserve. If we discover a user is misusing this feature on DEV to release Conduct-breaking material, we will act accordingly to hold the user accountable.
We're excited for you all to use this feature and hope that you'll share your feedback in the comments below.
To lock a discussion on a post, navigate to the Manage section of one of your posts. There are 3 ways to get there after you sign in:
/manageto the URL of your post.
- Visit your dashboard and click the Manage button next to the post you'd like to modify: .
- Visit your post and click the Manage button:
As noted on the confirmation page, users will not be able to add new comments when a discussion is locked, but locking a discussion does not remove existing comments.
When locking a discussion, you can provide additional context:
- reason - this will be displayed publicly on the post once you lock the discussion (see below). This is optional.
- notes - this is only visible by the post author and admins. It is not publicly visible. This is optional.
You also have the ability to unlock a discussion. To do this, repeat the first few steps above to navigate to the Manage page.
Click Unlock discussion and your audience is able to leave comments on your post again 🎉
Check out this PR to see how this feature was built:
What type of PR is this? (check all applicable)
- [x] Feature
This PR introduces functionality to allow article authors, admins, and super admins to lock discussions which basically prevents the ability for users to add any further comments to an article. We've also added some logic to allow a permitted user to include a
reason that will display publicly when a discussion is locked and
notes which are only visible to users permitted to lock the discussion.
Related Tickets & Documents
QA Instructions, Screenshots, Recordings
- Pull down this code.
- Fire up the Rails server locally -
- Write a post.
- Go to
/manageon your published post.
- Add a
- Lock the discussion.
- View your article - you should see the discussion is locked and you're unable to add a comment.
- Go back to
/manageon your post.
- Unlock the discussion.
- Go back to your post and leave a comment.
- [x] Yes
[Forem core team only] How will this change be communicated?
- [x] I'm not sure how best to communicate this change and need help