aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/nfb.py
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2016-03-26 02:19:24 +0600
committerSergey M․ <dstftw@gmail.com>2016-03-26 02:19:24 +0600
commit6e6bc8dae577c29c072ffc5c25078b5668435435 (patch)
tree600a978f35617628856094486422e13c78d67ee7 /youtube_dl/extractor/nfb.py
parent15707c7e024f1f29e7abd8ddaa362196ef2d4af6 (diff)
Use urlencode_postdata across the codebase
Diffstat (limited to 'youtube_dl/extractor/nfb.py')
-rw-r--r--youtube_dl/extractor/nfb.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/youtube_dl/extractor/nfb.py b/youtube_dl/extractor/nfb.py
index ba1eefafc..51e4a34f7 100644
--- a/youtube_dl/extractor/nfb.py
+++ b/youtube_dl/extractor/nfb.py
@@ -1,8 +1,10 @@
from __future__ import unicode_literals
from .common import InfoExtractor
-from ..compat import compat_urllib_parse_urlencode
-from ..utils import sanitized_Request
+from ..utils import (
+ sanitized_Request,
+ urlencode_postdata,
+)
class NFBIE(InfoExtractor):
@@ -40,7 +42,7 @@ class NFBIE(InfoExtractor):
request = sanitized_Request(
'https://www.nfb.ca/film/%s/player_config' % video_id,
- compat_urllib_parse_urlencode({'getConfig': 'true'}).encode('ascii'))
+ urlencode_postdata({'getConfig': 'true'}))
request.add_header('Content-Type', 'application/x-www-form-urlencoded')
request.add_header('X-NFB-Referer', 'http://www.nfb.ca/medias/flash/NFBVideoPlayer.swf')