diff --git a/src/interface/desktop/search.html b/src/interface/desktop/search.html index aa8aa662..ce368b9b 100644 --- a/src/interface/desktop/search.html +++ b/src/interface/desktop/search.html @@ -112,14 +112,14 @@ } else if ( item.additional.file.endsWith(".md") || item.additional.file.endsWith(".markdown") || - (item.additional.file.includes("issues") && item.additional.file.includes("github.com")) || - (item.additional.file.includes("commit") && item.additional.file.includes("github.com")) + (item.additional.file.includes("issues") && item.additional.source === "github") || + (item.additional.file.includes("commit") && item.additional.source === "github") ) { html += render_markdown(query, [item]); } else if (item.additional.file.endsWith(".pdf")) { html += render_pdf(query, [item]); - } else if (item.additional.file.includes("notion.so")) { + } else if (item.additional.source == "notion") { html += `
` + `${item.additional.heading}` + `

${item.entry}

` + `
`; } else if (item.additional.file.endsWith(".html")) { html += render_html(query, [item]); diff --git a/src/khoj/interface/web/search.html b/src/khoj/interface/web/search.html index 5331ea92..d3ddb595 100644 --- a/src/khoj/interface/web/search.html +++ b/src/khoj/interface/web/search.html @@ -112,14 +112,14 @@ } else if ( item.additional.file.endsWith(".md") || item.additional.file.endsWith(".markdown") || - (item.additional.file.includes("issues") && item.additional.file.includes("github.com")) || - (item.additional.file.includes("commit") && item.additional.file.includes("github.com")) + (item.additional.file.includes("issues") && item.additional.source === "github") || + (item.additional.file.includes("commit") && item.additional.source === "github") ) { html += render_markdown(query, [item]); } else if (item.additional.file.endsWith(".pdf")) { html += render_pdf(query, [item]); - } else if (item.additional.file.includes("notion.so")) { + } else if (item.additional.source === "notion") { html += `
` + `${item.additional.heading}` + `

${item.entry}

` + `
`; } else if (item.additional.file.endsWith(".html")) { html += render_html(query, [item]);