mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-08-03 17:54:54 +02:00
Fix:Mark media as finished if less than 5 seconds remain on a sync and call progress sync again when last track ends #635
This commit is contained in:
parent
6161daeef0
commit
93b8e11378
5 changed files with 18 additions and 6 deletions
|
@ -52,12 +52,12 @@ export default class CastPlayer extends EventEmitter {
|
|||
return
|
||||
}
|
||||
|
||||
// var currentItemId = media.currentItemId
|
||||
var currentItemId = media.media.itemId
|
||||
if (currentItemId && this.currentTrackIndex !== currentItemId - 1) {
|
||||
this.currentTrackIndex = currentItemId - 1
|
||||
}
|
||||
|
||||
// TODO: Emit finished event
|
||||
if (media.playerState !== this.castPlayerState) {
|
||||
this.emit('stateChange', media.playerState)
|
||||
this.castPlayerState = media.playerState
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue