From 9f1124b0bbc7e7aabfe21cce91224ce96334e8d4 Mon Sep 17 00:00:00 2001 From: Alexandre Boucey Date: Tue, 20 Jun 2017 15:25:08 +0200 Subject: [PATCH] Update omdbapi.py Fixed API key support for OMDb --- couchpotato/core/media/movie/providers/info/omdbapi.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/couchpotato/core/media/movie/providers/info/omdbapi.py b/couchpotato/core/media/movie/providers/info/omdbapi.py index ddb336e..e72762f 100644 --- a/couchpotato/core/media/movie/providers/info/omdbapi.py +++ b/couchpotato/core/media/movie/providers/info/omdbapi.py @@ -19,7 +19,7 @@ class OMDBAPI(MovieProvider): urls = { 'search': 'https://www.omdbapi.com/?apikey=%s&type=movie&%s', - 'info': 'https://www.omdbapi.com/?apikiey=%s&type=movie&i=%s', + 'info': 'https://www.omdbapi.com/?apikey=%s&type=movie&i=%s', } http_time_between_calls = 0 @@ -59,7 +59,8 @@ class OMDBAPI(MovieProvider): return {} cache_key = 'omdbapi.cache.%s' % identifier - cached = self.getCache(cache_key, self.urls['info'] % identifier, timeout = 3, headers = {'User-Agent': Env.getIdentifier()}) + url = self.urls['info'] % (self.getApiKey(), identifier) + cached = self.getCache(cache_key, url, timeout = 3, headers = {'User-Agent': Env.getIdentifier()}) if cached: result = self.parseMovie(cached)