mirror of
https://github.com/discourse/discourse.git
synced 2025-05-25 09:42:46 +08:00
FIX: disable flagging hidden posts
This commit is contained in:
@ -389,6 +389,16 @@ widgetTest(`flagging: can't flag`, {
|
||||
}
|
||||
});
|
||||
|
||||
widgetTest(`flagging: can't flag when post is hidden`, {
|
||||
template: '{{mount-widget widget="post" args=args}}',
|
||||
beforeEach() {
|
||||
this.set("args", { canFlag: true, hidden: true });
|
||||
},
|
||||
test(assert) {
|
||||
assert.ok(this.$("button.create-flag").length === 0);
|
||||
}
|
||||
});
|
||||
|
||||
widgetTest(`read indicator`, {
|
||||
template: '{{mount-widget widget="post" args=args}}',
|
||||
beforeEach() {
|
||||
|
Reference in New Issue
Block a user