From ff0ca6442eaaa66638ded8ec4f371989c9aa36da Mon Sep 17 00:00:00 2001 From: Mike Jones Date: Sat, 14 Oct 2023 00:16:57 +0100 Subject: [PATCH] fix: respect "hideWatched" preference in video feed --- src/components/FeedPage.vue | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/FeedPage.vue b/src/components/FeedPage.vue index 1c22ab3d..7f4a2dea 100644 --- a/src/components/FeedPage.vue +++ b/src/components/FeedPage.vue @@ -83,9 +83,14 @@ export default { }, filteredVideos(_this) { const selectedGroup = _this.channelGroups.filter(group => group.groupName == _this.selectedGroupName); + + const videos = this.getPreferenceBoolean("hideWatched", false) + ? this.videos.filter(video => !video.watched) + : this.videos; + return _this.selectedGroupName == "" - ? _this.videos - : _this.videos.filter(video => selectedGroup[0].channels.includes(video.uploaderUrl.substr(-11))); + ? videos + : videos.filter(video => selectedGroup[0].channels.includes(video.uploaderUrl.substr(-11))); }, }, mounted() {