This commit is contained in:
subnub
2020-05-11 12:32:15 -04:00
parent b0a2b171fe
commit 7e14d245dc
2 changed files with 11 additions and 6 deletions
@@ -215,8 +215,11 @@ class S3Service implements ChunkInterface {
req.on("close", () => {
console.log("req closed");
s3ReadStream.destroy();
})
//req.on("")
req.on("end", () => {
console.log("req end");
})
@@ -21,17 +21,19 @@ const awaitStreamVideo = (start: number, end:number, differenceStart: number,
//console.log(tempStorage[tempUUID] !== currentUUID, tempStorage[tempUUID])
if (tempStorage[tempUUID] !== currentUUID) {
// console.log("New Stream Requested, Desroying old stream");
console.log("New Stream Requested, Desroying old stream");
// streamsToErrorCatch.forEach((stream) => {
// stream.destroy();
// })
streamsToErrorCatch.forEach((stream) => {
stream.destroy();
})
// console.log("Old Stream Desroyed");
// resolve();
console.log("Old Stream Desroyed");
resolve();
//delete tempStorage[tempUUID];
}
console.log("stream passed", currentUUID);
// if (tempStorage[tempUUID] !== undefined && tempStorage[tempUUID] !== currentUUID) {
// console.log("New Stream Requested, Desroying old stream");