Add extension only for known protocols in ReleaseResource

pull/1722/head
Bogdan 1 year ago
parent 7c5409383e
commit f7d7cca982

@ -43,14 +43,14 @@ namespace Prowlarr.Api.V1.Search
{ {
get get
{ {
var extension = "torrent"; var extension = Protocol switch
if (Protocol == DownloadProtocol.Usenet)
{ {
extension = "nzb"; DownloadProtocol.Torrent => ".torrent",
} DownloadProtocol.Usenet => ".nzb",
_ => string.Empty
};
return $"{Title}.{extension}"; return $"{Title}{extension}";
} }
} }
} }

Loading…
Cancel
Save