mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-12-26 02:36:10 +00:00
remove some redundant code calls and do a shouldstop call in the add loop
This commit is contained in:
parent
f2772ebdbd
commit
25286717b3
2 changed files with 15 additions and 9 deletions
|
@ -74,6 +74,7 @@ class LibrarySync():
|
|||
|
||||
finally:
|
||||
WINDOW.setProperty("SyncDatabaseRunning", "false")
|
||||
utils.logMsg("Sync DB", "syncDatabase Exiting", 0)
|
||||
cursor.close()
|
||||
|
||||
return True
|
||||
|
@ -448,6 +449,10 @@ class LibrarySync():
|
|||
count = 0
|
||||
|
||||
for item in episodeData:
|
||||
|
||||
if(self.ShouldStop(pDialog)):
|
||||
return False
|
||||
|
||||
progressAction = "Adding"
|
||||
WriteKodiDB().addEpisodeToKodiLibrary(item, connection, cursor)
|
||||
|
||||
|
|
|
@ -150,8 +150,8 @@ class WriteKodiDB():
|
|||
port = addon.getSetting('port')
|
||||
host = addon.getSetting('ipaddress')
|
||||
server = host + ":" + port
|
||||
downloadUtils = DownloadUtils()
|
||||
userid = downloadUtils.getUserId()
|
||||
#downloadUtils = DownloadUtils()
|
||||
#userid = downloadUtils.getUserId()
|
||||
|
||||
timeInfo = API().getTimeInfo(MBitem)
|
||||
userData=API().getUserData(MBitem)
|
||||
|
@ -354,8 +354,8 @@ class WriteKodiDB():
|
|||
port = addon.getSetting('port')
|
||||
host = addon.getSetting('ipaddress')
|
||||
server = host + ":" + port
|
||||
downloadUtils = DownloadUtils()
|
||||
userid = downloadUtils.getUserId()
|
||||
#downloadUtils = DownloadUtils()
|
||||
#userid = downloadUtils.getUserId()
|
||||
|
||||
timeInfo = API().getTimeInfo(MBitem)
|
||||
people = API().getPeople(MBitem)
|
||||
|
@ -760,8 +760,8 @@ class WriteKodiDB():
|
|||
port = addon.getSetting('port')
|
||||
host = addon.getSetting('ipaddress')
|
||||
server = host + ":" + port
|
||||
downloadUtils = DownloadUtils()
|
||||
userid = downloadUtils.getUserId()
|
||||
#downloadUtils = DownloadUtils()
|
||||
#userid = downloadUtils.getUserId()
|
||||
|
||||
timeInfo = API().getTimeInfo(MBitem)
|
||||
userData=API().getUserData(MBitem)
|
||||
|
@ -986,8 +986,8 @@ class WriteKodiDB():
|
|||
port = addon.getSetting('port')
|
||||
host = addon.getSetting('ipaddress')
|
||||
server = host + ":" + port
|
||||
downloadUtils = DownloadUtils()
|
||||
userid = downloadUtils.getUserId()
|
||||
#downloadUtils = DownloadUtils()
|
||||
#userid = downloadUtils.getUserId()
|
||||
|
||||
timeInfo = API().getTimeInfo(MBitem)
|
||||
userData=API().getUserData(MBitem)
|
||||
|
@ -1353,3 +1353,4 @@ class WriteKodiDB():
|
|||
kodiMovie = ReadKodiDB().getKodiMovie(boxsetmovie["Id"])
|
||||
if kodiMovie != None:
|
||||
WriteKodiDB().updateProperty(kodiMovie,"set",strSet,"movie",True)
|
||||
|
Loading…
Reference in a new issue