aboutsummaryrefslogtreecommitdiffstats
path: root/hypervideo_dl/extractor/nrk.py
diff options
context:
space:
mode:
Diffstat (limited to 'hypervideo_dl/extractor/nrk.py')
-rw-r--r--hypervideo_dl/extractor/nrk.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/hypervideo_dl/extractor/nrk.py b/hypervideo_dl/extractor/nrk.py
index 88d08e5..384865a 100644
--- a/hypervideo_dl/extractor/nrk.py
+++ b/hypervideo_dl/extractor/nrk.py
@@ -3,7 +3,8 @@ import random
import re
from .common import InfoExtractor
-from ..compat import compat_HTTPError, compat_str
+from ..compat import compat_str
+from ..networking.exceptions import HTTPError
from ..utils import (
ExtractorError,
determine_ext,
@@ -148,7 +149,7 @@ class NRKIE(NRKBaseIE):
try:
return self._call_api(f'playback/{item}/program/{video_id}', video_id, item, query=query)
except ExtractorError as e:
- if isinstance(e.cause, compat_HTTPError) and e.cause.code == 400:
+ if isinstance(e.cause, HTTPError) and e.cause.status == 400:
return self._call_api(f'playback/{item}/{video_id}', video_id, item, query=query)
raise