FIX: Hide related topics when module is disabled (#461)
This commit is contained in:
parent
ba3c3951cf
commit
8bd8280427
|
@ -6,7 +6,10 @@ export default {
|
||||||
initialize(container) {
|
initialize(container) {
|
||||||
const settings = container.lookup("service:site-settings");
|
const settings = container.lookup("service:site-settings");
|
||||||
|
|
||||||
if (settings.ai_embeddings_semantic_related_topics_enabled) {
|
if (
|
||||||
|
settings.ai_embeddings_enabled &&
|
||||||
|
settings.ai_embeddings_semantic_related_topics_enabled
|
||||||
|
) {
|
||||||
withPluginApi("1.1.0", (api) => {
|
withPluginApi("1.1.0", (api) => {
|
||||||
api.modifyClass("model:post-stream", {
|
api.modifyClass("model:post-stream", {
|
||||||
pluginId: "discourse-ai",
|
pluginId: "discourse-ai",
|
||||||
|
|
Loading…
Reference in New Issue