mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-17 17:14:18 +02:00
New: Show source/seed info in manual search
This commit is contained in:
@@ -54,7 +54,7 @@ namespace NzbDrone.Api.Indexers
|
||||
private Response DownloadRelease(ReleaseResource release)
|
||||
{
|
||||
var remoteEpisode = _remoteEpisodeCache.Find(release.Guid);
|
||||
|
||||
|
||||
if (remoteEpisode == null)
|
||||
{
|
||||
_logger.Debug("Couldn't find requested release in cache, cache timeout probably expired.");
|
||||
@@ -142,6 +142,21 @@ namespace NzbDrone.Api.Indexers
|
||||
release.QualityWeight += release.Quality.Revision.Real * 10;
|
||||
release.QualityWeight += release.Quality.Revision.Version;
|
||||
|
||||
|
||||
var torrentRelease = downloadDecision.RemoteEpisode.Release as TorrentInfo;
|
||||
|
||||
if (torrentRelease != null)
|
||||
{
|
||||
release.Protocol = DownloadProtocol.Torrent;
|
||||
release.Seeders = torrentRelease.Seeders;
|
||||
//TODO: move this up the chains
|
||||
release.Leechers = torrentRelease.Peers - torrentRelease.Seeders;
|
||||
}
|
||||
else
|
||||
{
|
||||
release.Protocol = DownloadProtocol.Usenet;
|
||||
}
|
||||
|
||||
result.Add(release);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user