mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-11-30 08:40:48 +00:00
Change suppress to False unless really needed
This is how it really was before yesterday's commit to re-enable the optionality
This commit is contained in:
parent
d647463bb4
commit
03416513cf
@ -227,7 +227,7 @@ class CreateFiles():
|
||||
trailerUrl = None
|
||||
if item.get("LocalTrailerCount") != None and item.get("LocalTrailerCount") > 0:
|
||||
itemTrailerUrl = "http://" + server + "/mediabrowser/Users/" + userid + "/Items/" + item.get("Id") + "/LocalTrailers?format=json"
|
||||
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=True, popup=0 )
|
||||
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=False, popup=0 )
|
||||
if(jsonData != ""):
|
||||
trailerItem = json.loads(jsonData)
|
||||
if trailerItem[0].get("LocationType") == "FileSystem":
|
||||
@ -289,7 +289,7 @@ class CreateFiles():
|
||||
utils.logMsg("MB3 Syncer","creating Theme file " + themeFile,2)
|
||||
#theme music link
|
||||
themeMusicUrl = "http://" + server + "/mediabrowser/Items/" + item["Id"] + "/ThemeSongs?format=json"
|
||||
jsonData = downloadUtils.downloadUrl(themeMusicUrl, suppress=True, popup=0 )
|
||||
jsonData = downloadUtils.downloadUrl(themeMusicUrl, suppress=False, popup=0 )
|
||||
if(jsonData != ""):
|
||||
themeMusic = json.loads(jsonData)
|
||||
if(themeMusic != None and themeMusic["TotalRecordCount"] > 0):
|
||||
|
@ -33,7 +33,7 @@ class ReadEmbyDB():
|
||||
else:
|
||||
url = server + '/mediabrowser/Users/' + userid + '/items?ParentId=' + id + sortstring + '&Fields=CumulativeRunTimeTicks&Recursive=true&SortOrder=Descending&IncludeItemTypes=Movie&CollapseBoxSetItems=false&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
if(result.has_key('Items')):
|
||||
@ -62,7 +62,7 @@ class ReadEmbyDB():
|
||||
else:
|
||||
url = server + '/mediabrowser/Users/' + userid + '/items?' + sortstring + '&Fields=CumulativeRunTimeTicks&Recursive=true&SortOrder=Descending&IncludeItemTypes=MusicVideo&CollapseBoxSetItems=false&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
if(result.has_key('Items')):
|
||||
@ -109,7 +109,7 @@ class ReadEmbyDB():
|
||||
else:
|
||||
url = server + '/mediabrowser/Users/' + userid + '/Items?' + sortstring + '&Fields=CumulativeRunTimeTicks&Recursive=true&SortOrder=Descending&IncludeItemTypes=Series&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
if(result.has_key('Items')):
|
||||
@ -130,7 +130,7 @@ class ReadEmbyDB():
|
||||
|
||||
url = 'http://' + server + '/Shows/' + tvShowId + '/Seasons?UserId=' + userid + '&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
if(result.has_key('Items')):
|
||||
@ -154,7 +154,7 @@ class ReadEmbyDB():
|
||||
else:
|
||||
url = server + '/mediabrowser/Users/' + userid + '/Items?ParentId=' + showId + '&IsVirtualUnaired=false&IsMissing=False&SortBy=SortName&Fields=Name,SortName,CumulativeRunTimeTicks&Recursive=true&SortOrder=Ascending&IncludeItemTypes=Episode&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
@ -178,7 +178,7 @@ class ReadEmbyDB():
|
||||
else:
|
||||
url = server + '/mediabrowser/Users/' + userid + '/Items?Limit=20&SortBy=DateCreated&IsVirtualUnaired=false&IsMissing=False&Fields=ParentId,Name,SortName,CumulativeRunTimeTicks&Recursive=true&SortOrder=Descending&IncludeItemTypes=Episode&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
@ -243,7 +243,7 @@ class ReadEmbyDB():
|
||||
server = host + ":" + port
|
||||
|
||||
viewsUrl = server + "/mediabrowser/Users/" + userid + "/Views?format=json&ImageTypeLimit=1"
|
||||
jsonData = DownloadUtils().downloadUrl(viewsUrl, suppress=True, popup=0 )
|
||||
jsonData = DownloadUtils().downloadUrl(viewsUrl, suppress=False, popup=0 )
|
||||
collections=[]
|
||||
|
||||
if(jsonData != ""):
|
||||
@ -253,7 +253,7 @@ class ReadEmbyDB():
|
||||
for view in views:
|
||||
if view.get("Type") == 'UserView': # Need to grab the real main node
|
||||
newViewsUrl = server + '/mediabrowser/Users/' + userid + '/items?ParentId=' + view.get("Id") + '&SortBy=SortName&SortOrder=Ascending&format=json&ImageTypeLimit=1'
|
||||
jsonData = DownloadUtils().downloadUrl(newViewsUrl, suppress=True, popup=0 )
|
||||
jsonData = DownloadUtils().downloadUrl(newViewsUrl, suppress=False, popup=0 )
|
||||
if(jsonData != ""):
|
||||
newViews = json.loads(jsonData)
|
||||
newViews = newViews.get("Items")
|
||||
@ -287,7 +287,7 @@ class ReadEmbyDB():
|
||||
|
||||
url = server + '/mediabrowser/Users/' + userid + '/Items?SortBy=SortName&IsVirtualUnaired=false&IsMissing=False&Fields=Name,SortName,CumulativeRunTimeTicks&Recursive=true&SortOrder=Ascending&IncludeItemTypes=BoxSet&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
@ -308,7 +308,7 @@ class ReadEmbyDB():
|
||||
|
||||
url = server + '/mediabrowser/Users/' + userid + '/Items?ParentId=' + boxsetId + '&Fields=ItemCounts&format=json&ImageTypeLimit=1'
|
||||
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=True, popup=0)
|
||||
jsonData = downloadUtils.downloadUrl(url, suppress=False, popup=0)
|
||||
|
||||
if jsonData != None and jsonData != "":
|
||||
result = json.loads(jsonData)
|
||||
|
@ -211,7 +211,7 @@ class WebSocketThread(threading.Thread):
|
||||
userUrl = "http://" + host + ":" + port + "/mediabrowser/System/Info?format=json"
|
||||
|
||||
downloadUtils = DownloadUtils()
|
||||
jsonData = downloadUtils.downloadUrl(userUrl, suppress=True, popup=1 )
|
||||
jsonData = downloadUtils.downloadUrl(userUrl, suppress=False, popup=1 )
|
||||
if(jsonData == ""):
|
||||
return -1
|
||||
|
||||
|
@ -136,7 +136,7 @@ class WriteKodiDB():
|
||||
trailerUrl = None
|
||||
if MBitem.get("LocalTrailerCount") != None and MBitem.get("LocalTrailerCount") > 0:
|
||||
itemTrailerUrl = "http://" + server + "/mediabrowser/Users/" + userid + "/Items/" + MBitem.get("Id") + "/LocalTrailers?format=json"
|
||||
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=True, popup=0 )
|
||||
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=False, popup=0 )
|
||||
if(jsonData != ""):
|
||||
trailerItem = json.loads(jsonData)
|
||||
if trailerItem[0].get("LocationType") == "FileSystem":
|
||||
@ -299,7 +299,7 @@ class WriteKodiDB():
|
||||
trailerUrl = None
|
||||
if MBitem.get("LocalTrailerCount") != None and MBitem.get("LocalTrailerCount") > 0:
|
||||
itemTrailerUrl = "http://" + server + "/mediabrowser/Users/" + userid + "/Items/" + MBitem.get("Id") + "/LocalTrailers?format=json"
|
||||
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=True, popup=0 )
|
||||
jsonData = downloadUtils.downloadUrl(itemTrailerUrl, suppress=False, popup=0 )
|
||||
if(jsonData != ""):
|
||||
trailerItem = json.loads(jsonData)
|
||||
trailerUrl = "plugin://plugin.video.mb3sync/?id=" + trailerItem[0].get("Id") + '&mode=play'
|
||||
|
Loading…
Reference in New Issue
Block a user