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
1 changed files with 4 additions and 4 deletions

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"