mirror of
https://github.com/keven1024/015.git
synced 2026-05-26 07:08:02 +00:00
fix(front): ensure chunks default to an empty array in FileUploadProgressView for improved upload handling
This commit is contained in:
@@ -168,7 +168,7 @@ const handleCreate = async (fileId: string) => {
|
||||
hash,
|
||||
},
|
||||
})
|
||||
const { id, chunk_size, type: createType, chunks } = createData?.data || {}
|
||||
const { id, chunk_size, type: createType, chunks = [] } = createData?.data || {}
|
||||
uploadfile.id = id
|
||||
uploadfile.uploadInfo = {
|
||||
chunks: Object.fromEntries(chunks.map((index: number) => [index - 1, { status: 'success', createdAt: dayjs().unix() }])),
|
||||
|
||||
Reference in New Issue
Block a user