mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-05 17:56:18 +00:00
Use Math.Clamp in GetGuideDays
This commit is contained in:
@@ -159,7 +159,7 @@ public class GuideManager : IGuideManager
|
||||
var config = _config.GetLiveTvConfiguration();
|
||||
|
||||
return config.GuideDays.HasValue
|
||||
? Math.Max(1, Math.Min(config.GuideDays.Value, MaxGuideDays))
|
||||
? Math.Clamp(config.GuideDays.Value, 1, MaxGuideDays)
|
||||
: 7;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user