mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-12-16 11:37:58 +02:00
added sample check for remote episode.
This commit is contained in:
parent
b07bc713bb
commit
1665bfa6ac
@ -0,0 +1,20 @@
|
||||
using NzbDrone.Core.IndexerSearch.Definitions;
|
||||
using NzbDrone.Core.Parser.Model;
|
||||
|
||||
namespace NzbDrone.Core.DecisionEngine.Specifications
|
||||
{
|
||||
public class NotSampleSpecification : IDecisionEngineSpecification
|
||||
{
|
||||
public string RejectionReason { get { return "Sample"; } }
|
||||
|
||||
public bool IsSatisfiedBy(RemoteEpisode subject, SearchCriteriaBase searchCriteria)
|
||||
{
|
||||
if (subject.Release.Title.ToLower().Contains("sample") && subject.Release.Size < 70.Megabytes())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
@ -188,6 +188,7 @@
|
||||
<Compile Include="DecisionEngine\IDecisionEngineSpecification.cs" />
|
||||
<Compile Include="DecisionEngine\Specifications\CutoffSpecification.cs" />
|
||||
<Compile Include="DecisionEngine\Specifications\NotRestrictedReleaseSpecification.cs" />
|
||||
<Compile Include="DecisionEngine\Specifications\NotSampleSpecification.cs" />
|
||||
<Compile Include="DecisionEngine\Specifications\RssSync\ProperSpecification.cs" />
|
||||
<Compile Include="DecisionEngine\Specifications\Search\SeasonMatchSpecification.cs" />
|
||||
<Compile Include="DecisionEngine\Specifications\Search\DailyEpisodeMatchSpecification.cs" />
|
||||
|
@ -34,7 +34,6 @@ public UpdatePackage AvailableUpdate()
|
||||
if (latestAvailable == null)
|
||||
{
|
||||
_logger.ProgressDebug("No update available.");
|
||||
return null;
|
||||
}
|
||||
|
||||
return latestAvailable;
|
||||
|
@ -11,6 +11,7 @@ define(
|
||||
if (!img.src.contains(placeHolder)) {
|
||||
img.src = placeHolder;
|
||||
}
|
||||
img.onerror = null;
|
||||
};
|
||||
|
||||
Handlebars.registerHelper('defaultImg', function () {
|
||||
|
Loading…
Reference in New Issue
Block a user