aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/nfb.py
diff options
context:
space:
mode:
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')