From 1bd657f07d0e740e90535a8411f4cd6d292009bc Mon Sep 17 00:00:00 2001 From: advplyr Date: Thu, 2 Jun 2022 16:31:52 -0500 Subject: [PATCH] Fix:Mark as finished once media has ended #635 --- client/components/modals/libraries/EditLibrary.vue | 4 ---- server/objects/user/MediaProgress.js | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/client/components/modals/libraries/EditLibrary.vue b/client/components/modals/libraries/EditLibrary.vue index 8071fd14..db87d1db 100644 --- a/client/components/modals/libraries/EditLibrary.vue +++ b/client/components/modals/libraries/EditLibrary.vue @@ -62,10 +62,6 @@ export default { { value: 'podcast', text: 'Podcasts' - }, - { - value: 'video', - text: 'Videos' } ] } diff --git a/server/objects/user/MediaProgress.js b/server/objects/user/MediaProgress.js index bb5e1d62..eb24b1e5 100644 --- a/server/objects/user/MediaProgress.js +++ b/server/objects/user/MediaProgress.js @@ -91,7 +91,7 @@ class MediaProgress { var timeRemaining = this.duration - this.currentTime // If time remaining is less than 5 seconds then mark as finished - if ((this.progress >= 1 || (!isNaN(timeRemaining) && timeRemaining < 5)) && !this.isFinished) { + if ((this.progress >= 1 || (!isNaN(timeRemaining) && timeRemaining < 5))) { this.isFinished = true this.finishedAt = Date.now() this.progress = 1