mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-16 10:03:51 -07:00
cleaned up refresh series info
This commit is contained in:
parent
7a96cb763a
commit
49949bbe74
15 changed files with 361 additions and 240 deletions
|
@ -1,5 +1,4 @@
|
|||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Linq;
|
||||
using NzbDrone.Common.Messaging;
|
||||
using NzbDrone.Core.Datastore;
|
||||
|
@ -11,6 +10,7 @@ namespace NzbDrone.Core.MediaFiles
|
|||
EpisodeFile GetFileByPath(string path);
|
||||
List<EpisodeFile> GetFilesBySeries(int seriesId);
|
||||
List<EpisodeFile> GetFilesBySeason(int seriesId, int seasonNumber);
|
||||
bool Exists(string path);
|
||||
}
|
||||
|
||||
|
||||
|
@ -27,6 +27,11 @@ namespace NzbDrone.Core.MediaFiles
|
|||
return Query.SingleOrDefault(c => c.Path == path);
|
||||
}
|
||||
|
||||
public bool Exists(string path)
|
||||
{
|
||||
return Query.Any(c => c.Path == path);
|
||||
}
|
||||
|
||||
public List<EpisodeFile> GetFilesBySeries(int seriesId)
|
||||
{
|
||||
return Query.Where(c => c.SeriesId == seriesId).ToList();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue