From 047d5a666aa376387fbf0b8540c9d6dcfc74eacd Mon Sep 17 00:00:00 2001 From: Killer069 <65385476+killer069@users.noreply.github.com> Date: Mon, 13 Sep 2021 11:14:30 +0530 Subject: [PATCH] only first stream would retry now --- play-dl/YouTube/classes/LiveStream.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/play-dl/YouTube/classes/LiveStream.ts b/play-dl/YouTube/classes/LiveStream.ts index 597a3f8..8674562 100644 --- a/play-dl/YouTube/classes/LiveStream.ts +++ b/play-dl/YouTube/classes/LiveStream.ts @@ -180,7 +180,7 @@ export class Stream { "range" : `bytes=${this.bytes_count}-${end >= this.content_length ? '' : end}` } }) - if(Number(stream.statusCode) >= 400){ + if(Number(stream.statusCode) >= 400 && this.bytes_count === 0){ this.cleanup() await this.retry() this.loop()