Skip to content

Commit

Permalink
Fix reset mounted files (#390)
Browse files Browse the repository at this point in the history
  • Loading branch information
oeway authored May 17, 2024
1 parent 69e6434 commit 3f5dc9d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions public/chat/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1041,6 +1041,10 @@ <h3 class="text-center">Welcome to BioImage.IO Chatbot</h3>
$('#mount-folder-btn').show();
if (mountedFolder) {
await worker.mount("/mnt", mountedFolder);
$('#mount-folder-btn').text(`Mount Files (${mountedFolder.name})`);
}
else{
$('#mount-folder-btn').text(`Mount Files`);
}
worker = w;
console.log("Worker created:", worker);
Expand Down Expand Up @@ -1520,6 +1524,7 @@ <h3 class="text-center">Welcome to BioImage.IO Chatbot</h3>
chat_history.length = 0; // Clear the chat history
code = ''; // Reset code
error_message = ''; // Reset error message
mountedFolder = null;
$('.message-holder').empty(); // Clear the messages
initializeService();
}
Expand Down

0 comments on commit 3f5dc9d

Please sign in to comment.