mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 18:30:26 -06:00
FIX: Show hidden posts to staff members. (#11171)
When looking at the list of a user's deleted posts, those that are also hidden are not listed. Context: https://meta.discourse.org/t/flagged-deleted-posts-do-not-show-up-on-users-profile/168527
This commit is contained in:
parent
0f38fc42e2
commit
5ae82c0492
@ -1,16 +1,22 @@
|
||||
import Component from "@ember/component";
|
||||
import { propertyEqual } from "discourse/lib/computed";
|
||||
import { computed } from "@ember/object";
|
||||
import { actionDescription } from "discourse/widgets/post-small-action";
|
||||
|
||||
export default Component.extend({
|
||||
classNameBindings: [
|
||||
":user-stream-item",
|
||||
":item", // DEPRECATED: 'item' class
|
||||
"item.hidden",
|
||||
"hidden",
|
||||
"item.deleted:deleted",
|
||||
"moderatorAction",
|
||||
],
|
||||
|
||||
hidden: computed("item.hidden", function () {
|
||||
return (
|
||||
this.get("item.hidden") && !(this.currentUser && this.currentUser.staff)
|
||||
);
|
||||
}),
|
||||
moderatorAction: propertyEqual(
|
||||
"item.post_type",
|
||||
"site.post_types.moderator_action"
|
||||
|
Loading…
Reference in New Issue
Block a user