lemmy icon indicating copy to clipboard operation
lemmy copied to clipboard

Handle displaying of deleted and removed posts/comments (fixes #2624)

Open Nutomic opened this issue 2 years ago • 2 comments

Makes it so that deleted and removed posts/comments are only shown on the creator's profile page in the following cases:

  • When user views his own profile, he can view all posts/comments which he deleted himself (but not those which were deleted by mod actions)
  • When admin views user profile, he can see all posts/comments which were deleted by mod actions (but not those deleted by the user himself)

The existing code would also show deleted/removed posts and comments to admins/mods in post listings and search results, I dont think thats desirable.

Nutomic avatar Jun 23 '23 08:06 Nutomic

  • did some cleanup for tests but not finished yet (still failing)
  • changed it so that a user can always see their own deleted posts, not only in profile
  • might be useful to show removed posts/comments in moderator view but not sure about this (https://github.com/LemmyNet/lemmy/pull/3176)

Nutomic avatar Jul 14 '23 14:07 Nutomic

Clippy failing.

dessalines avatar Jul 14 '23 16:07 dessalines

~~Need to merge https://github.com/LemmyNet/lemmy/pull/3613 first.~~

Edit: actually not, because this PR doesnt change PostView::read. So this is ready to merge

Nutomic avatar Jul 17 '23 11:07 Nutomic

Added another change to allow returning own deleted posts from PostView::read, which makes https://github.com/LemmyNet/lemmy/pull/3613 obsolete. I tested to confirm that its working for unauthenticated users.

Nutomic avatar Jul 19 '23 11:07 Nutomic