mirror of
https://github.com/YuzuZensai/NekoMelody.git
synced 2026-01-31 14:57:58 +00:00
🐛 fix: Queue not playing next song
This commit is contained in:
@@ -19,6 +19,7 @@ export class SeekableStream {
|
||||
private firstTick: boolean = true;
|
||||
private destroyed: boolean = false;
|
||||
private event: EventEmitter = new EventEmitter();
|
||||
private started: boolean = false;
|
||||
|
||||
private bytesReceived: number = 0;
|
||||
private bytesRead: number = 0;
|
||||
@@ -54,6 +55,10 @@ export class SeekableStream {
|
||||
//if (seekTime !== 0) this.seek();
|
||||
}
|
||||
|
||||
public start() {
|
||||
this.started = true;
|
||||
}
|
||||
|
||||
private async tick(seekTime?: number) {
|
||||
if (this.destroyed) {
|
||||
console.debug(
|
||||
@@ -152,6 +157,8 @@ export class SeekableStream {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!this.started) return;
|
||||
|
||||
const isBufferSufficient =
|
||||
this.stream.readableLength >= this.bytesPerRequestLimit;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user