Don't call omdbapi without api key

This commit is contained in:
gunmantheh 2017-05-30 22:04:32 +02:00
parent 3766fa3b84
commit 39c5cbe1a1

View file

@ -1063,6 +1063,8 @@ def find_imdbid(dirName, inputName, omdbApiKey):
logger.debug("Opening URL: {0}".format(url))
if not omdbApiKey:
return
try:
r = requests.get(url, params={'apikey': omdbApiKey, 'y': year, 't': title},
verify=False, timeout=(60, 300))