1
0
Fork 0
mirror of https://github.com/evilhero/mylar synced 2024-12-27 01:57:01 +00:00

Swapping NZBGet HTTP/HTTPS check in URL

HTTPS was never being set, because the search was finding 'http' first every time.
This commit is contained in:
Jonathan Putney 2016-08-02 15:40:33 -04:00 committed by evilhero
parent e11555899f
commit ab8a87b4ec

View file

@ -2130,12 +2130,12 @@ def searcher(nzbprov, nzbname, comicinfo, link, IssueID, ComicID, tmpprov, direc
#nzb.get
if mylar.USE_NZBGET:
from xmlrpclib import ServerProxy
if mylar.NZBGET_HOST[:4] == 'http':
tmpapi = "http://"
nzbget_host = mylar.NZBGET_HOST[7:]
elif mylar.NZBGET_HOST[:5] == 'https':
if mylar.NZBGET_HOST[:5] == 'https':
tmpapi = "https://"
nzbget_host = mylar.NZBGET_HOST[8:]
elif mylar.NZBGET_HOST[:4] == 'http':
tmpapi = "http://"
nzbget_host = mylar.NZBGET_HOST[7:]
else:
logger.error("You have an invalid nzbget hostname specified. Exiting")
return "nzbget-fail"