Sleep a bit before marking an item watched

This commit is contained in:
tomkat83 2017-02-18 16:45:57 +01:00
parent 1a24146e48
commit 81f0fe1157

View file

@ -6,6 +6,7 @@ import logging
from urllib import urlencode
from ntpath import dirname
from datetime import datetime
from xbmc import sleep
import artwork
from utils import tryEncode, tryDecode, settings, window, kodiSQL, \
@ -166,6 +167,7 @@ class Items(object):
% (item['ratingKey'], str(complete), MARK_PLAYED_AT), 1)
if complete >= MARK_PLAYED_AT:
log.info('Marking as completely watched in Kodi', 1)
sleep(500)
try:
item['viewCount'] += 1
except TypeError: