mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-07-02 13:34:53 +02:00
Fix: temp fix for aac codec error by forcing aac encode #172, Change: Failed streams will close the stream and show error
This commit is contained in:
parent
8316a8c18b
commit
ac72ec1317
6 changed files with 52 additions and 12 deletions
|
@ -28,8 +28,12 @@ class StreamManager {
|
|||
this.streams = this.streams.filter(s => s.id !== stream.id)
|
||||
}
|
||||
|
||||
async openStream(client, audiobook) {
|
||||
var stream = new Stream(this.StreamsPath, client, audiobook)
|
||||
async openStream(client, audiobook, transcodeOptions = {}) {
|
||||
if (!client || !client.user) {
|
||||
Logger.error('[StreamManager] Cannot open stream invalid client', client)
|
||||
return
|
||||
}
|
||||
var stream = new Stream(this.StreamsPath, client, audiobook, transcodeOptions)
|
||||
|
||||
stream.on('closed', () => {
|
||||
this.removeStream(stream)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue