1
0
mirror of https://github.com/yt-dlp/yt-dlp synced 2025-12-18 15:15:42 +07:00

[downloader/external] add can_download mathod for checking downloader availibilty and support

This commit is contained in:
remitamine
2016-03-13 14:53:17 +01:00
parent 91ee320bfa
commit 2cb99ebbd0
2 changed files with 6 additions and 2 deletions

View File

@@ -59,6 +59,10 @@ def available(cls):
def supports(cls, info_dict):
return info_dict['protocol'] in ('http', 'https', 'ftp', 'ftps')
@classmethod
def can_download(cls, info_dict):
return cls.available() and cls.supports(info_dict)
def _option(self, command_option, param):
return cli_option(self.params, command_option, param)