Merge branch 'master' into blacklisting
This commit is contained in:
commit
0b6ad3d0c2
|
@ -92,6 +92,27 @@
|
||||||
"unpackopts":"3",
|
"unpackopts":"3",
|
||||||
"verbosity":""
|
"verbosity":""
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"avg_age":"580d",
|
||||||
|
"cat":"tv",
|
||||||
|
"eta":"01:45 PM Mon 23 Jan",
|
||||||
|
"filename":"Invalid Item",
|
||||||
|
"index":1,
|
||||||
|
"mb":"419.23",
|
||||||
|
"mbleft":"419.23",
|
||||||
|
"missing":0,
|
||||||
|
"msgid":5657628,
|
||||||
|
"nzo_id":"SABnzbd_nzo_dgrzts",
|
||||||
|
"percentage":"0",
|
||||||
|
"priority":"Normal",
|
||||||
|
"script":"None",
|
||||||
|
"size":"419 MB",
|
||||||
|
"sizeleft":"419 MB",
|
||||||
|
"status":"Queued",
|
||||||
|
"timeleft":"86:01:55",
|
||||||
|
"unpackopts":"3",
|
||||||
|
"verbosity":""
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"status":"Paused",
|
"status":"Paused",
|
||||||
"index":1,
|
"index":1,
|
||||||
|
|
|
@ -94,7 +94,7 @@ namespace NzbDrone.Core.Test.ProviderTests.SabProviderTests
|
||||||
|
|
||||||
var result = Mocker.Resolve<SabProvider>().GetQueue();
|
var result = Mocker.Resolve<SabProvider>().GetQueue();
|
||||||
|
|
||||||
result.Should().HaveCount(3);
|
result.Should().HaveCount(4);
|
||||||
}
|
}
|
||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
|
@ -209,6 +209,12 @@ namespace NzbDrone.Core.Test.ProviderTests.SabProviderTests
|
||||||
result.Should().BeFalse();
|
result.Should().BeFalse();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[TearDown]
|
||||||
|
public void TearDown()
|
||||||
|
{
|
||||||
|
ExceptionVerification.IgnoreWarns();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,5 +1,6 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Globalization;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
@ -421,7 +422,8 @@ namespace NzbDrone.Core
|
||||||
|
|
||||||
if (match.Count != 0)
|
if (match.Count != 0)
|
||||||
{
|
{
|
||||||
var value = Convert.ToDecimal(Regex.Replace(match[0].Groups["value"].Value, "\\,", ""));
|
var cultureInfo = new CultureInfo("en-US");
|
||||||
|
var value = Decimal.Parse(Regex.Replace(match[0].Groups["value"].Value, "\\,", ""), cultureInfo);
|
||||||
|
|
||||||
var unit = match[0].Groups["unit"].Value;
|
var unit = match[0].Groups["unit"].Value;
|
||||||
|
|
||||||
|
|
|
@ -75,7 +75,7 @@ namespace NzbDrone.Core.Providers
|
||||||
|
|
||||||
public virtual bool IsInQueue(EpisodeParseResult newParseResult)
|
public virtual bool IsInQueue(EpisodeParseResult newParseResult)
|
||||||
{
|
{
|
||||||
var queue = GetQueue();
|
var queue = GetQueue().Where(c => c.ParseResult != null);
|
||||||
|
|
||||||
return queue.Any(sabQueueItem => String.Equals(sabQueueItem.ParseResult.CleanTitle, newParseResult.Series.CleanTitle, StringComparison.InvariantCultureIgnoreCase) &&
|
return queue.Any(sabQueueItem => String.Equals(sabQueueItem.ParseResult.CleanTitle, newParseResult.Series.CleanTitle, StringComparison.InvariantCultureIgnoreCase) &&
|
||||||
sabQueueItem.ParseResult.EpisodeNumbers.Any(e => newParseResult.EpisodeNumbers.Contains(e)) &&
|
sabQueueItem.ParseResult.EpisodeNumbers.Any(e => newParseResult.EpisodeNumbers.Contains(e)) &&
|
||||||
|
|
Loading…
Reference in New Issue