projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f838875
)
[pladform] Fix format quality sorting
author
Sergey M․
<dstftw@gmail.com>
Sun, 8 Mar 2015 12:09:47 +0000
(18:09 +0600)
committer
Sergey M․
<dstftw@gmail.com>
Sun, 8 Mar 2015 12:09:47 +0000
(18:09 +0600)
youtube_dl/extractor/pladform.py
patch
|
blob
|
history
diff --git
a/youtube_dl/extractor/pladform.py
b/youtube_dl/extractor/pladform.py
index 926e368a27a60f6b9cbe93c8e49885ebf81d3d46..abde34b94659574041469e8f2f4a8b0e4e903bb1 100644
(file)
--- a/
youtube_dl/extractor/pladform.py
+++ b/
youtube_dl/extractor/pladform.py
@@
-6,6
+6,7
@@
from ..utils import (
ExtractorError,
int_or_none,
xpath_text,
+ qualities,
)
@@
-55,9
+56,12
@@
class PladformIE(InfoExtractor):
'%s returned error: %s' % (self.IE_NAME, video.text),
expected=True)
+ quality = qualities(('ld', 'sd', 'hd'))
+
formats = [{
'url': src.text,
'format_id': src.get('quality'),
+ 'quality': quality(src.get('quality')),
} for src in video.findall('./src')]
self._sort_formats(formats)