aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2017-09-10 19:09:27 +0700
committerSergey M․ <dstftw@gmail.com>2017-09-10 19:09:27 +0700
commitc3dd44e08577c2ae0d08951037db5d1db7a321c3 (patch)
tree1b0b929300d4a1917b14314e91dfdb6dda4a9a5c
parentc7e327c4d46a9b72f3f707710194dccf6eee50d9 (diff)
downloadyoutube-dl-c3dd44e08577c2ae0d08951037db5d1db7a321c3.tar.xz
[rutube] Use bool_or_none
-rw-r--r--youtube_dl/extractor/rutube.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/youtube_dl/extractor/rutube.py b/youtube_dl/extractor/rutube.py
index 5a184879f..828c03b48 100644
--- a/youtube_dl/extractor/rutube.py
+++ b/youtube_dl/extractor/rutube.py
@@ -12,9 +12,10 @@ from ..compat import (
)
from ..utils import (
determine_ext,
- unified_timestamp,
- try_get,
+ bool_or_none,
int_or_none,
+ try_get,
+ unified_timestamp,
)
@@ -42,7 +43,7 @@ class RutubeBaseIE(InfoExtractor):
'age_limit': age_limit,
'view_count': int_or_none(video.get('hits')),
'comment_count': int_or_none(video.get('comments_count')),
- 'is_live': video.get('is_livestream'),
+ 'is_live': bool_or_none(video.get('is_livestream')),
}