|
|
|
@ -38,37 +38,15 @@ namespace NzbDrone.Core.Download.Clients.UTorrent
|
|
|
|
|
|
|
|
|
|
protected override string AddFromMagnetLink(RemoteEpisode remoteEpisode, string hash, string magnetLink)
|
|
|
|
|
{
|
|
|
|
|
_proxy.AddTorrentFromUrl(magnetLink, Settings);
|
|
|
|
|
_proxy.SetTorrentLabel(hash, Settings.TvCategory, Settings);
|
|
|
|
|
|
|
|
|
|
var isRecentEpisode = remoteEpisode.IsRecentEpisode();
|
|
|
|
|
|
|
|
|
|
if (isRecentEpisode && Settings.RecentTvPriority == (int)UTorrentPriority.First ||
|
|
|
|
|
!isRecentEpisode && Settings.OlderTvPriority == (int)UTorrentPriority.First)
|
|
|
|
|
{
|
|
|
|
|
_proxy.MoveTorrentToTopInQueue(hash, Settings);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return hash;
|
|
|
|
|
throw new DownloadClientException("Episodes are not working with Radarr");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override string AddFromTorrentFile(RemoteEpisode remoteEpisode, string hash, string filename, byte[] fileContent)
|
|
|
|
|
{
|
|
|
|
|
_proxy.AddTorrentFromFile(filename, fileContent, Settings);
|
|
|
|
|
_proxy.SetTorrentLabel(hash, Settings.TvCategory, Settings);
|
|
|
|
|
|
|
|
|
|
var isRecentEpisode = remoteEpisode.IsRecentEpisode();
|
|
|
|
|
|
|
|
|
|
if (isRecentEpisode && Settings.RecentTvPriority == (int)UTorrentPriority.First ||
|
|
|
|
|
!isRecentEpisode && Settings.OlderTvPriority == (int)UTorrentPriority.First)
|
|
|
|
|
{
|
|
|
|
|
_proxy.MoveTorrentToTopInQueue(hash, Settings);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return hash;
|
|
|
|
|
throw new DownloadClientException("Episodes are not working with Radarr");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override string AddFromMagnetLink(RemoteMovie remoteEpisode, string hash, string magnetLink)
|
|
|
|
|
protected override string AddFromMagnetLink(RemoteMovie remoteMovie, string hash, string magnetLink)
|
|
|
|
|
{
|
|
|
|
|
_proxy.AddTorrentFromUrl(magnetLink, Settings);
|
|
|
|
|
_proxy.SetTorrentLabel(hash, Settings.TvCategory, Settings);
|
|
|
|
@ -84,7 +62,7 @@ namespace NzbDrone.Core.Download.Clients.UTorrent
|
|
|
|
|
return hash;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override string AddFromTorrentFile(RemoteMovie remoteEpisode, string hash, string filename, byte[] fileContent)
|
|
|
|
|
protected override string AddFromTorrentFile(RemoteMovie remoteMovie, string hash, string filename, byte[] fileContent)
|
|
|
|
|
{
|
|
|
|
|
_proxy.AddTorrentFromFile(filename, fileContent, Settings);
|
|
|
|
|
_proxy.SetTorrentLabel(hash, Settings.TvCategory, Settings);
|
|
|
|
|