mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-12-25 10:16:11 +00:00
Ensure deliveryurl is an actual url
This commit is contained in:
parent
043a2574b1
commit
3a79341065
1 changed files with 2 additions and 2 deletions
|
@ -465,7 +465,7 @@ class PlayUtils(object):
|
||||||
if stream['Type'] == 'Subtitle' and stream['IsExternal'] and stream['IsTextSubtitleStream']:
|
if stream['Type'] == 'Subtitle' and stream['IsExternal'] and stream['IsTextSubtitleStream']:
|
||||||
index = stream['Index']
|
index = stream['Index']
|
||||||
|
|
||||||
if 'DeliveryUrl' in stream:
|
if 'DeliveryUrl' in stream and stream['DeliveryUrl'].lower().startswith('http'):
|
||||||
url = "%s/emby%s" % (self.info['ServerAddress'], stream['DeliveryUrl'])
|
url = "%s/emby%s" % (self.info['ServerAddress'], stream['DeliveryUrl'])
|
||||||
else:
|
else:
|
||||||
url = self.get_subtitles(source, stream, index)
|
url = self.get_subtitles(source, stream, index)
|
||||||
|
@ -621,7 +621,7 @@ class PlayUtils(object):
|
||||||
|
|
||||||
def get_subtitles(self, source, stream, index):
|
def get_subtitles(self, source, stream, index):
|
||||||
|
|
||||||
if 'DeliveryUrl' in stream:
|
if 'DeliveryUrl' in stream and stream['DeliveryUrl'].lower().startswith('http'):
|
||||||
url = "%s/emby%s" % (self.info['ServerAddress'], stream['DeliveryUrl'])
|
url = "%s/emby%s" % (self.info['ServerAddress'], stream['DeliveryUrl'])
|
||||||
else:
|
else:
|
||||||
url = ("%s/emby/Videos/%s/%s/Subtitles/%s/Stream.%s?api_key=%s" %
|
url = ("%s/emby/Videos/%s/%s/Subtitles/%s/Stream.%s?api_key=%s" %
|
||||||
|
|
Loading…
Reference in a new issue