kopia lustrzana https://dev.funkwhale.audio/funkwhale/funkwhale
feat(ui): update upload status with error message if import failed
Part-of: <https://dev.funkwhale.audio/funkwhale/funkwhale/-/merge_requests/2308>environments/review-front-2029-1110q1/deployments/16693
rodzic
ce522dbf59
commit
7f93311150
|
@ -0,0 +1 @@
|
|||
Update upload status when import fails (#1999)
|
|
@ -128,6 +128,15 @@ useWebSocketHandler('import.status_updated', async (event) => {
|
|||
// TODO (wvffle): Why?
|
||||
await nextTick()
|
||||
|
||||
if (event.new_status === 'errored') {
|
||||
for (const file of files.value) {
|
||||
if (file.response?.uuid === event.upload.uuid) {
|
||||
file.error = event.new_status
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
uploads[event.old_status] -= 1
|
||||
uploads[event.new_status] += 1
|
||||
uploads.objects[event.upload.uuid] = event.upload
|
||||
|
|
Ładowanie…
Reference in New Issue