Remove debug log

This commit is contained in:
2025-10-31 13:55:38 +11:00
parent 2f340e1a10
commit 4b798d6d9b
@@ -241,7 +241,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
}
const tasks = status?.tasks || []
const sortedTasks = [...tasks].sort((a, b) =>
const sortedTasks = [...tasks].sort((a, b) =>
new Date(b.created_at).getTime() - new Date(a.created_at).getTime()
)
@@ -290,9 +290,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
</div>
<div className="space-y-2">
{autoJobs.map((job) => {
// Debug: log job status
console.log('Job:', job.song_name, 'Status:', job.status, 'Should show retry:', (job.status === 'failed' || job.status === 'cancelled'));
return (
<div
key={job.id}
@@ -325,7 +323,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
Confirm
</Button>
)}
{/* Cancel button for active jobs */}
{(job.status === 'pending' || job.status === 'searching' || job.status === 'downloading') && (
<Button
@@ -338,7 +336,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
<XCircle className="h-4 w-4" />
</Button>
)}
{/* Retry button for failed/cancelled jobs */}
{(job.status === 'failed' || job.status === 'cancelled') && (
<Button
@@ -351,7 +349,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
<RefreshCw className="h-4 w-4" />
</Button>
)}
{/* Delete button - always visible */}
<Button
variant="ghost"
@@ -395,7 +393,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
className="w-16 h-16 object-cover rounded"
/>
)}
<div className="flex-1 min-w-0">
<h4 className="font-medium truncate">{task.title}</h4>
{task.artist && (
@@ -437,7 +435,7 @@ export default function DownloadCenter({ onPlayMusic }: DownloadCenterProps) {
<Play className="h-5 w-5" />
</Button>
)}
{(task.status === 'completed' || task.status === 'failed') && (
<Button
size="icon"