Full partial content stream
This commit is contained in:
parent
7716332b1f
commit
1b12af714f
|
@ -37,11 +37,10 @@ export class Webserver {
|
|||
|
||||
let [from, to] = this.from_to([range.from, range.from+this.chunk_size], d.total_size);
|
||||
|
||||
let contentLength = this.partial_size + 1;
|
||||
if(contentLength+from > d.total_size) contentLength = d.total_size-from;
|
||||
let contentLength = d.total_size-from;
|
||||
let headers = {
|
||||
"Content-Range": `bytes ${from}-${from+contentLength}/${d.total_size+1}`,
|
||||
"Range": `bytes=${from}-${from+contentLength}/${d.total_size+1}`,
|
||||
"Content-Range": `bytes ${from}-${d.total_size}/${d.total_size+1}`,
|
||||
"Range": `bytes=${from}-${d.total_size}/${d.total_size+1}`,
|
||||
"Accept-Ranges": "bytes",
|
||||
"Content-Length": contentLength,
|
||||
"Content-Type": "application/octet-stream",
|
||||
|
|
Reference in a new issue