aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/TV
diff options
context:
space:
mode:
authorBill Thornton <billt2006@gmail.com>2022-03-01 00:49:29 -0500
committerBill Thornton <billt2006@gmail.com>2022-03-01 00:50:16 -0500
commit055c63bdeeb257bda1ec45090d6d0797f9e1262a (patch)
tree9a9bdb0caba0b112fea591d1c186b891838ed18f /Emby.Server.Implementations/TV
parent7c9aa63382d3d0e4a3e3285732f469026b98aa07 (diff)
Include played and unplayed results in the same next up request
Diffstat (limited to 'Emby.Server.Implementations/TV')
-rw-r--r--Emby.Server.Implementations/TV/TVSeriesManager.cs10
1 files changed, 9 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/TV/TVSeriesManager.cs b/Emby.Server.Implementations/TV/TVSeriesManager.cs
index a47650a32..c0d8487ce 100644
--- a/Emby.Server.Implementations/TV/TVSeriesManager.cs
+++ b/Emby.Server.Implementations/TV/TVSeriesManager.cs
@@ -140,7 +140,15 @@ namespace Emby.Server.Implementations.TV
var currentUser = user;
var allNextUp = seriesKeys
- .Select(i => GetNextUp(i, currentUser, dtoOptions, request.Rewatching));
+ .Select(i => GetNextUp(i, currentUser, dtoOptions, false));
+
+ if (request.EnableRewatching)
+ {
+ allNextUp = allNextUp.Concat(
+ seriesKeys.Select(i => GetNextUp(i, currentUser, dtoOptions, true))
+ )
+ .OrderByDescending(i => i.Item1);
+ }
// If viewing all next up for all series, remove first episodes
// But if that returns empty, keep those first episodes (avoid completely empty view)