mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-02 21:19:12 +00:00
Fix setting chat session title from Desktop app
Pass auth headers to not have the chat session title update request fail
This commit is contained in:
@@ -918,7 +918,7 @@
|
|||||||
let newTitle = conversationTitleInput.value;
|
let newTitle = conversationTitleInput.value;
|
||||||
if (newTitle != null) {
|
if (newTitle != null) {
|
||||||
let editURL = `/api/chat/title?client=web&conversation_id=${incomingConversationId}&title=${newTitle}`;
|
let editURL = `/api/chat/title?client=web&conversation_id=${incomingConversationId}&title=${newTitle}`;
|
||||||
fetch(`${hostURL}${editURL}` , { method: "PATCH" })
|
fetch(`${hostURL}${editURL}` , { method: "PATCH", headers })
|
||||||
.then(response => response.ok ? response.json() : Promise.reject(response))
|
.then(response => response.ok ? response.json() : Promise.reject(response))
|
||||||
.then(data => {
|
.then(data => {
|
||||||
conversationButton.textContent = newTitle;
|
conversationButton.textContent = newTitle;
|
||||||
|
|||||||
Reference in New Issue
Block a user