Fix respecting restart playing videos setting

This commit is contained in:
Arkadiusz Fal 2022-08-29 17:58:26 +02:00
parent 3a05462965
commit ba07c410f5
2 changed files with 3 additions and 1 deletions

View File

@ -227,7 +227,7 @@ extension PlayerModel {
let newItem = enqueueVideo(video, atTime: time, prepending: true) let newItem = enqueueVideo(video, atTime: time, prepending: true)
advanceToItem(newItem!) advanceToItem(newItem!, at: time)
} }
func removeQueueItems() { func removeQueueItems() {

View File

@ -32,6 +32,8 @@ struct PlayerQueueItem: Hashable, Identifiable, Defaults.Serializable {
} }
var shouldRestartPlaying: Bool { var shouldRestartPlaying: Bool {
guard Defaults[.watchedVideoPlayNowBehavior] == .continue else { return true }
guard let seconds = playbackTime?.seconds else { guard let seconds = playbackTime?.seconds else {
return false return false
} }