|
|
|
@ -67,7 +67,7 @@ namespace NzbDrone.Core.Jobs
|
|
|
|
|
|
|
|
|
|
new ScheduledTask
|
|
|
|
|
{
|
|
|
|
|
Interval = new [] { _configService.RssSyncInterval, 10 }.Max(),
|
|
|
|
|
Interval = GetRssSyncInterval(),
|
|
|
|
|
TypeName = typeof(RssSyncCommand).FullName
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
@ -106,6 +106,18 @@ namespace NzbDrone.Core.Jobs
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private int GetRssSyncInterval()
|
|
|
|
|
{
|
|
|
|
|
var interval = _configService.RssSyncInterval;
|
|
|
|
|
|
|
|
|
|
if (interval > 0 && interval < 10)
|
|
|
|
|
{
|
|
|
|
|
return 10;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return interval;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void Handle(CommandExecutedEvent message)
|
|
|
|
|
{
|
|
|
|
|
var scheduledTask = _scheduledTaskRepository.All().SingleOrDefault(c => c.TypeName == message.Command.GetType().FullName);
|
|
|
|
|