Skip to content

Commit 0427d8a

Browse files
Fix DRM scheme detetion
1 parent 62d3ac6 commit 0427d8a

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/inputstreamhelper.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,14 @@ def __init__(self, protocol, drm=None):
1919
self._log('Platform information: {0}'.format(platform.uname()))
2020

2121
self.protocol = protocol
22-
self.drm = drm
2322
if self.protocol not in config.INPUTSTREAM_PROTOCOLS:
2423
raise self.InputStreamException('UnsupportedProtocol')
2524
else:
2625
self._inputstream_addon = config.INPUTSTREAM_PROTOCOLS[self.protocol]
27-
if self.drm and self.drm not in config.DRM_SCHEMES:
26+
if not drm or drm not in config.DRM_SCHEMES:
2827
raise self.InputStreamException('UnsupportedDRMScheme')
2928
else:
30-
self.drm = config.DRM_SCHEMES[self.drm]
29+
self.drm = config.DRM_SCHEMES[drm]
3130

3231
class InputStreamException(Exception):
3332
pass

0 commit comments

Comments
 (0)