# 主题搜索对未列出主题无效

**URL:** https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881
**Category:** Bug
**Tags:** unlisting
**Created:** [2018年五月6日 15:42 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881 "2018-05-06T15:42:14Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![TechnoBear](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/technobear/32/40546_2.png) [@TechnoBear](https://meta.discourse.org/u/TechnoBear)
#### Post date: [2018年五月6日 15:42 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881/1 "2018-05-06T15:42:14Z")

</div>

If a topic is unlisted, topic search returns no results for any search term. Omitting unlisted topics from a general search makes sense, but if I’m actually viewing the topic, surely I should also be able to search it?

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [2018年五月6日 21:20 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881/3 "2018-05-06T21:20:01Z")

</div>

Wait do you mean using the search box from within the unlisted topic? I am a little unclear.

---

<div class="post-metadata">

### Author: ![cpradio](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/cpradio/32/4970_2.png) [@cpradio](https://meta.discourse.org/u/cpradio)
#### Post date: [2018年五月6日 21:51 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881/4 "2018-05-06T21:51:46Z")

</div>

Yes, that is correct. When viewing an unlisted topic, click on the search, make sure “search this topic” is checked, any query you type returns zero results.

Exact reproducible steps on instance that is running latest.

1. Open a fairly long topic
2. Mark it as unlisted
3. Click search icon
4. Check “Search this topic” checkbox
5. Enter search query
6. No results found
7. Re-list topic
8. Click search icon
9. Check “Search this topic” checkbox
10. Enter same search query
11. Results found

---

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [2018年五月6日 21:57 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881/5 "2018-05-06T21:57:15Z")

</div>

With shaky pen and custom CSS, here’s a screen capture

 ![unlisted-search](https://global.discourse-cdn.com/meta/original/3X/e/1/e18acc878b04fbed182c565cf74b933683c009e1.png)

---

<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: [2018年五月7日 09:54 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881/6 "2018-05-07T09:54:45Z")

</div>

Thanks for reporting that @TechnoBear 👌. It’s now fixed 🍓

[https://github.com/discourse/discourse/commit/a98aae3bcd5dd4456c0e15715f4f4306caa35393](https://github.com/discourse/discourse/commit/a98aae3bcd5dd4456c0e15715f4f4306caa35393)

---

<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: [2018年五月7日 16:00 UTC](https://meta.discourse.org/t/topic-search-doesn-t-work-for-unlisted-topics/86881/7 "2018-05-07T16:00:01Z")

</div>

This topic was automatically closed after 6 hours. New replies are no longer allowed.
