# 未列出主题的事件显示在日历上

**URL:** <https://meta.discourse.org/t/events-from-unlisted-topics-show-on-calendar/406032>\
**Category:** Bug\
**Tags:** events, fixed\
**Created:** [2026年六月24日 15:23 UTC](https://meta.discourse.org/t/events-from-unlisted-topics-show-on-calendar/406032 "2026-06-24T15:23:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![RGJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rgj/32/523185_2.png) [@RGJ](https://meta.discourse.org/u/RGJ)\
**Post date:** [2026年六月24日 15:23 UTC](https://meta.discourse.org/t/events-from-unlisted-topics-show-on-calendar/406032/1 "2026-06-24T15:23:44Z")

</div>

复现步骤：

- 启用日历插件
- 启用事件功能
- 在某个分类上启用日历
- 创建一个带有事件的主题
- 将该主题取消公开（取消公开也可能是由于垃圾邮件标记或版主操作导致的）

结果：

- 该主题从主题列表中消失（对非工作人员和较低信任等级的用户而言）
- 查看日历，发现事件仍然对所有人可见。

预期结果：

- 来自已取消公开主题的事件不应显示在日历中

---

<div class="post-metadata">

**Author:** ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)\
**Post date:** [2026年六月25日 13:26 UTC](https://meta.discourse.org/t/events-from-unlisted-topics-show-on-calendar/406032/3 "2026-06-25T13:26:08Z")

</div>

感谢你的报告 @RGJ 👍 这是修复方案

> <https://github.com/discourse/discourse/pull/41194>
>
> Previously, the calendar — along with the \`/upcoming-events\` page and the \`.ics\`… subscription feed — listed events from unlisted topics to everyone, because \`EventFinder\` scoped events with \`Topic.listable\_topics\`, which only excludes private messages and never filters out unlisted (\`visible: false\`) topics. Unlisting a topic (manually, or as a side effect of spam flagging or a moderator action) therefore removed it from the topic list but left its event on the calendar for all users.
> 
> This change makes \`EventFinder\`'s \`listable\_topics\` apply the \`visible\` scope unless the user can see unlisted topics (\`Guardian#can\_see\_unlisted\_topics?\`), mirroring how \`TopicQuery\` filters topic listings: staff and TL4 users still see events from unlisted topics, while everyone else no longer does.
> 
> Meta: https://meta.discourse.org/t/events-from-unlisted-topics-show-on-calendar/406032

---

<div class="post-metadata">

**Author:** ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)\
**Post date:** [2026年六月27日 13:32 UTC](https://meta.discourse.org/t/events-from-unlisted-topics-show-on-calendar/406032/4 "2026-06-27T13:32:41Z")

</div>


