refactor: simplify auto download check logic by removing unnecessary progress updates

This commit is contained in:
Will Miao
2025-08-08 19:58:20 +08:00
parent 4c33c9d256
commit 0906271aa9

View File

@@ -763,22 +763,7 @@ class ExampleImagesManager {
const data = await response.json();
if (data.success) {
// Only show progress if there are actually items to download
if (data.status && data.status.total > 0) {
this.isDownloading = true;
this.isPaused = false;
this.hasShownCompletionToast = false;
this.startTime = new Date();
this.updateUI(data.status);
this.showProgressPanel();
this.startProgressUpdates();
this.updateDownloadButtonText();
console.log(`Auto download started: ${data.status.total} items to process`);
} else {
console.log('Auto download check completed - no new items to download');
}
} else {
if (!data.success) {
console.warn('Auto download check failed:', data.error);
}
} catch (error) {