mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-20 21:54:25 -04:00
No more dupes and house cleaner added
This commit is contained in:
@@ -1,7 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using NzbDrone.Core.Datastore;
|
||||
using NzbDrone.Core.Messaging.Events;
|
||||
|
||||
@@ -12,7 +9,6 @@ namespace NzbDrone.Core.MediaFiles
|
||||
{
|
||||
List<EpisodeFile> GetFilesBySeries(int seriesId);
|
||||
List<EpisodeFile> GetFilesBySeason(int seriesId, int seasonNumber);
|
||||
EpisodeFile FindFileByPath(string path, bool includeExtension = true);
|
||||
}
|
||||
|
||||
|
||||
@@ -34,15 +30,5 @@ namespace NzbDrone.Core.MediaFiles
|
||||
.AndWhere(c => c.SeasonNumber == seasonNumber)
|
||||
.ToList();
|
||||
}
|
||||
|
||||
public EpisodeFile FindFileByPath(string path, bool includeExtension = true)
|
||||
{
|
||||
if (includeExtension)
|
||||
{
|
||||
return Query.SingleOrDefault(c => c.Path == path);
|
||||
}
|
||||
|
||||
return Query.SingleOrDefault(c => c.Path.StartsWith(Path.ChangeExtension(path, "")));
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user