We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c6ed170 commit 103832fCopy full SHA for 103832f
routes/_apis/artifactcache/caches/[cacheId].patch.ts
@@ -37,11 +37,10 @@ export default defineEventHandler(async (event) => {
37
throw createError({ statusCode: 400, statusMessage: 'Invalid content-range header' })
38
}
39
40
+ // TODO find a better way to calculate chunk size
41
// this should be the correct chunk size except for the last chunk
- const chunkSize = Math.floor(start / (end - start))
42
// this should handle the incorrect chunk size of the last chunk by just setting it to the limit of 10000 (for s3)
43
- // TODO find a better way to calculate chunk size
44
- const chunkIndex = Math.min(chunkSize, 10_000)
+ const chunkIndex = Math.min(Math.floor(start / (end - start)), 9999)
45
46
const adapter = await useStorageAdapter()
47
await adapter.uploadChunk({
0 commit comments