mirror of
https://github.com/mwalbeck/podfox.git
synced 2025-04-15 02:18:29 +00:00
Add support for video podcasts and easy addition of more mimetypes
This commit is contained in:
parent
33b16a1ddf
commit
3f8e9e1146
1 changed files with 6 additions and 2 deletions
|
@ -40,6 +40,11 @@ from time import mktime
|
|||
|
||||
CONFIGURATION = {}
|
||||
|
||||
mimetypes = [
|
||||
'audio/ogg',
|
||||
'audio/mpeg',
|
||||
'video/mp4'
|
||||
]
|
||||
|
||||
def print_err(err):
|
||||
print(Fore.RED + Style.BRIGHT + err +
|
||||
|
@ -160,8 +165,7 @@ def episodes_from_feed(d):
|
|||
for link in entry.links:
|
||||
if not hasattr(link, 'type'):
|
||||
continue
|
||||
if hasattr(link, 'type') and (link.type == 'audio/mpeg' or
|
||||
link.type == 'audio/ogg'):
|
||||
if hasattr(link, 'type') and (link.type in mimetypes):
|
||||
if hasattr(entry, 'title'):
|
||||
episode_title = entry.title
|
||||
else:
|
||||
|
|
Loading…
Add table
Reference in a new issue