From 4a83aae573662e082f1b322d5664685dbe746c4b Mon Sep 17 00:00:00 2001 From: croneter Date: Sat, 16 Feb 2019 17:59:03 +0100 Subject: [PATCH] Fix TypeError: unsupported operand type(s) for /: 'NoneType' and 'int' --- resources/lib/playback.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/lib/playback.py b/resources/lib/playback.py index 66c396a0..0873b9c6 100644 --- a/resources/lib/playback.py +++ b/resources/lib/playback.py @@ -414,7 +414,7 @@ def _conclude_playback(playqueue, pos): if v.KODIVERSION >= 18 and api: # Kodi 18 Alpha 3 broke StartOffset try: - percent = item.offset / api.runtime() * 100.0 + percent = (item.offset or api.resume_point()) / api.runtime() * 100.0 except ZeroDivisionError: percent = 0.0 LOG.debug('Resuming at %s percent', percent)