[common] Remove _multiple_opener_supported()

Currently YoutubeDL is the only class used in extractors
This commit is contained in:
Yen Chi Hsuan 2015-02-28 00:09:34 +08:00
parent 5c9a26dae5
commit 603251c34d

View File

@ -1053,14 +1053,8 @@ class InfoExtractor(object):
def _get_automatic_captions(self, *args, **kwargs):
raise NotImplementedError("This method must be implemented by subclasses")
def _multiple_opener_supported(self):
return hasattr(self._downloader, 'use_opener')
def _use_opener(self, opener_name):
if self._multiple_opener_supported():
self._downloader.use_opener(opener_name)
else:
raise Exception('Multiple opener not supported')
self._downloader.use_opener(opener_name)
class SearchInfoExtractor(InfoExtractor):