mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-21 14:03:29 -07:00
SeasonProvider GetLatestSeason added
This commit is contained in:
parent
57f5b3ddc2
commit
ac20da426b
2 changed files with 6 additions and 0 deletions
|
@ -27,6 +27,11 @@ namespace NzbDrone.Core.Providers
|
|||
return _sonicRepo.All<Season>().Where(s => s.SeriesId == seriesId).ToList();
|
||||
}
|
||||
|
||||
public Season GetLatestSeason(int seriesId)
|
||||
{
|
||||
return _sonicRepo.All<Season>().Where(s => s.SeriesId == seriesId).OrderBy(s => s.SeasonNumber).Last();
|
||||
}
|
||||
|
||||
public void EnsureSeason(int seriesId, int seasonId, int seasonNumber)
|
||||
{
|
||||
if (_sonicRepo.Exists<Season>(s => s.SeasonId == seasonId))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue