mirror of
https://github.com/mollersuite/monofile.git
synced 2024-11-22 05:46:26 -08:00
workpls
This commit is contained in:
parent
58da5da26e
commit
213ae8e8a5
|
@ -194,6 +194,11 @@ let fgRQH = async (req:express.Request,res:express.Response) => {
|
||||||
res.setHeader("Content-Length",f.byteSize)
|
res.setHeader("Content-Length",f.byteSize)
|
||||||
}
|
}
|
||||||
res.status(200)
|
res.status(200)
|
||||||
|
|
||||||
|
if (req.header("range") == "bytes=0-") {
|
||||||
|
res.status(206)
|
||||||
|
}
|
||||||
|
|
||||||
f.dataStream.pipe(res)
|
f.dataStream.pipe(res)
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
ServeError(res,err.status,err.message)
|
ServeError(res,err.status,err.message)
|
||||||
|
|
Loading…
Reference in a new issue