fix(migration): stop polling when job status is 'completed'

Backend returns "completed" but pollJob only checked "done"/"complete",
causing infinite polling and oscillating UI state.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Paul Huliganga 2026-04-21 14:26:28 -04:00
parent e521fd8e58
commit 5cf415d38a
1 changed files with 1 additions and 1 deletions

View File

@ -207,7 +207,7 @@ export async function pollJob(jobId, onProgress) {
const data = await api.migrate.batchStatus(jobId); const data = await api.migrate.batchStatus(jobId);
if (onProgress) onProgress(data); if (onProgress) onProgress(data);
if (data.status === 'done' || data.status === 'complete') { if (data.status === 'done' || data.status === 'complete' || data.status === 'completed') {
setState('lastMigrationResults', data); setState('lastMigrationResults', data);
resolve(data); resolve(data);
} else if (data.status === 'failed') { } else if (data.status === 'failed') {