# “AI 검색 발견” 설정을 켜고 끄지 않습니다

**URL:** https://meta.discourse.org/t/toggling-the-ai-search-discoveries-preference-doesnt-work/391135
**Category:** Bug
**Tags:** ai
**Created:** [12월 12, 2025, 9:57오전 UTC](https://meta.discourse.org/t/toggling-the-ai-search-discoveries-preference-doesnt-work/391135 "2025-12-12T09:57:29Z")
**Posts on this page:** 1
**Showing post:** 5

<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: [12월 12, 2025, 1:09오후 UTC](https://meta.discourse.org/t/toggling-the-ai-search-discoveries-preference-doesnt-work/391135/5 "2025-12-12T13:09:51Z")

</div>

`modifyClass`을 사용해야 할지 망설여지지만, 더 나은 방법을 찾지 못했습니다 🤔 (cc @david / @cvx)

> <https://github.com/discourse/discourse/pull/36658>
>
> The "Enable AI search discoveries" checkbox in user preferences wasn't persistin…g changes. The UI showed "saved" but the value never reached the database.
> 
> The Interface controller's \`saveAttrNames\` is a computed property that returns a new array on each access. While the plugin called \`addSaveableUserOptionField()\`, this only registers the field with the User model. The controller filters which fields to save via \`saveAttrNames\`, and since \`ai\_search\_discoveries\` wasn't in that list, it was excluded from the save request.
> 
> Fix by using \`modifyClass\` to extend the controller's \`save()\` action, pushing \`ai\_search\_discoveries\` to \`saveAttrNames\` at the moment of saving before calling the parent method.
> 
> Ref - meta/t/391135

---

_[View the full topic](https://meta.discourse.org/t/toggling-the-ai-search-discoveries-preference-doesnt-work/391135)._
