Second attempt at fixing playcount situation

This should also reflect the actual Emby playcount. The websocket didn't
echo, but what I did is kill the echo caused by the video library update
after userdata change happens.
This commit is contained in:
angelblue05 2015-05-17 00:37:53 -05:00
commit ddb7ec4bbd
6 changed files with 33 additions and 33 deletions

View file

@ -117,9 +117,8 @@ class WriteKodiVideoDB():
else:
dateadded = None
playcount = 0
if userData.get("PlayCount") == "1":
playcount = 1
if userData.get("PlayCount") != "0":
playcount = int(userData.get('PlayCount'))
else:
playcount = None #playcount must be set to NULL in the db
@ -267,9 +266,8 @@ class WriteKodiVideoDB():
else:
dateadded = None
playcount = 0
if userData.get("PlayCount") == "1":
playcount = 1
if userData.get("PlayCount") != "0":
playcount = int(userData.get('PlayCount'))
else:
playcount = None #playcount must be set to NULL in the db
@ -550,9 +548,8 @@ class WriteKodiVideoDB():
else:
lastplayed = None
playcount = None
if userData.get("PlayCount") == "1":
playcount = 1
if userData.get("PlayCount") != "0":
playcount = int(userData.get('PlayCount'))
else:
playcount = None #playcount must be set to NULL in the db