mirror of
https://github.com/flarum/framework.git
synced 2025-05-22 22:59:57 +08:00
Make discussion "hidden" state more explicit
Previously a discussion was classified on the front-end as "hidden" if it had zero posts. This was technically a correct statement as the discussion would not be visible to the public... but it also meant that a discussion with zero posts (like one awaiting approval) was impossible for the OP to delete/hide (i.e. indicate that they made a mistake and they don't want the discussion to be approved).
This commit is contained in:
@ -30,7 +30,7 @@ Object.assign(Discussion.prototype, {
|
||||
|
||||
hideTime: Model.attribute('hideTime', Model.transformDate),
|
||||
hideUser: Model.hasOne('hideUser'),
|
||||
isHidden: computed('hideTime', 'commentsCount', (hideTime, commentsCount) => !!hideTime || commentsCount === 0),
|
||||
isHidden: computed('hideTime', hideTime => !!hideTime),
|
||||
|
||||
canReply: Model.attribute('canReply'),
|
||||
canRename: Model.attribute('canRename'),
|
||||
|
Reference in New Issue
Block a user