Fix refresh error: Replace const reassignment with property deletion

Co-authored-by: catlog22 <28037070+catlog22@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2025-12-08 06:29:27 +00:00
parent 9232947fb0
commit de3d15c099

View File

@@ -157,9 +157,9 @@ async function refreshWorkspace() {
// Reload data from server
const data = await loadDashboardData(projectPath);
if (data) {
// Update stores
sessionDataStore = {};
liteTaskDataStore = {};
// Update stores - clear existing properties
Object.keys(sessionDataStore).forEach(k => delete sessionDataStore[k]);
Object.keys(liteTaskDataStore).forEach(k => delete liteTaskDataStore[k]);
// Populate stores
[...(data.activeSessions || []), ...(data.archivedSessions || [])].forEach(s => {