Timothy Jaeryang Baek 2 月之前
父節點
當前提交
7e971f9dd1
共有 1 個文件被更改,包括 0 次插入4 次删除
  1. 0 4
      src/lib/components/chat/Chat.svelte

+ 0 - 4
src/lib/components/chat/Chat.svelte

@@ -1266,7 +1266,6 @@
 		}
 		}
 
 
 		prompt = '';
 		prompt = '';
-		await tick();
 
 
 		// Reset chat input textarea
 		// Reset chat input textarea
 		const chatInputElement = document.getElementById('chat-input');
 		const chatInputElement = document.getElementById('chat-input');
@@ -1308,9 +1307,6 @@
 			history.messages[messages.at(-1).id].childrenIds.push(userMessageId);
 			history.messages[messages.at(-1).id].childrenIds.push(userMessageId);
 		}
 		}
 
 
-		// Wait until history/message have been updated
-		await tick();
-
 		// focus on chat input
 		// focus on chat input
 		const chatInput = document.getElementById('chat-input');
 		const chatInput = document.getElementById('chat-input');
 		chatInput?.focus();
 		chatInput?.focus();