diff --git a/apps/web/src/routes/projects/[projectId]/branches/[branchId]/stack/[changeId]/+page.svelte b/apps/web/src/routes/projects/[projectId]/branches/[branchId]/stack/[changeId]/+page.svelte index 3049692ce9..8a7d2b3f78 100644 --- a/apps/web/src/routes/projects/[projectId]/branches/[branchId]/stack/[changeId]/+page.svelte +++ b/apps/web/src/routes/projects/[projectId]/branches/[branchId]/stack/[changeId]/+page.svelte @@ -10,7 +10,7 @@ let patch: any = {}; let stack: any = {}; let status: any = {}; - let chats: any = []; + let events: any = []; let key: any = ''; let uuid: any = ''; @@ -256,7 +256,7 @@ } function fetchAndUpdateChat() { - fetch(env.PUBLIC_APP_HOST + 'api/chat_messages/' + data.projectId + '/chats/' + data.changeId, { + fetch(env.PUBLIC_APP_HOST + 'api/patch_events/' + data.projectId + '/patch/' + data.changeId, { method: 'GET', headers: { 'X-AUTH-TOKEN': key || '' @@ -266,7 +266,7 @@ .then((data) => { console.log(data); setTimeout(() => { - chats = data; + events = data; setTimeout(() => { scrollToBottom(); }, 150); // I don't know how to DOM in Svelte, but it takes a second @@ -342,6 +342,7 @@ .then((data) => { console.log('sign off', data); getPatchStatus(); + fetchAndUpdateChat(); }); } } @@ -469,11 +470,13 @@ {/if} {/if}