[natgeo:episodeguide] Do not shadow url from outer scope
authorSergey M․ <dstftw@gmail.com>
Thu, 4 Aug 2016 16:21:04 +0000 (23:21 +0700)
committerSergey M․ <dstftw@gmail.com>
Thu, 4 Aug 2016 16:21:04 +0000 (23:21 +0700)
youtube_dl/extractor/nationalgeographic.py

index fe43d4bc8b4c809ebbe0c728c00243f553ba02c1..4bffcf704d8c85c9424ff311f03b0b907070c8f6 100644 (file)
@@ -161,8 +161,8 @@ class NationalGeographicEpisodeGuideIE(ThePlatformIE):
             r'<div[^>]+class="select-seasons[^"]*".*?<a[^>]*>(.*?)</a>',
             webpage, 'selected season')
         entries = [
-            self.url_result(self._proto_relative_url(url), 'NationalGeographic')
-            for url in re.findall('(?s)<div[^>]+class="col-inner"[^>]*?>.*?<a[^>]+href="([^"]+)"', webpage)]
+            self.url_result(self._proto_relative_url(entry_url), 'NationalGeographic')
+            for entry_url in re.findall('(?s)<div[^>]+class="col-inner"[^>]*?>.*?<a[^>]+href="([^"]+)"', webpage)]
         return self.playlist_result(
             entries, '%s-%s' % (display_id, selected_season.lower().replace(' ', '-')),
             '%s - %s' % (show, selected_season))