diff --git a/resources/lib/variables.py b/resources/lib/variables.py index 0e032981..98c345f6 100644 --- a/resources/lib/variables.py +++ b/resources/lib/variables.py @@ -27,7 +27,7 @@ ADDON_VERSION = _ADDON.getAddonInfo('version') KODILANGUAGE = xbmc.getLanguage(xbmc.ISO_639_1) KODIVERSION = int(xbmc.getInfoLabel("System.BuildVersion")[:2]) KODILONGVERSION = xbmc.getInfoLabel('System.BuildVersion') -KODI_PROFILE = xbmc.translatePath("special://profile") +KODI_PROFILE = tryDecode(xbmc.translatePath("special://profile")) if xbmc.getCondVisibility('system.platform.osx'): PLATFORM = "MacOSX" diff --git a/service.py b/service.py index 696a87b9..1c7fc843 100644 --- a/service.py +++ b/service.py @@ -30,7 +30,7 @@ sys_path.append(_base_resource) ############################################################################### -from utils import settings, window, language as lang, dialog +from utils import settings, window, language as lang, dialog, tryDecode from userclient import UserClient import initialsetup from kodimonitor import KodiMonitor @@ -164,11 +164,12 @@ class Service(): counter = 0 while not monitor.abortRequested(): - if window('plex_kodiProfile') != kodiProfile: + if tryDecode(window('plex_kodiProfile')) != kodiProfile: # Profile change happened, terminate this thread and others log.warn("Kodi profile was: %s and changed to: %s. " "Terminating old PlexKodiConnect thread." - % (kodiProfile, window('plex_kodiProfile'))) + % (kodiProfile, + tryDecode(window('plex_kodiProfile')))) break # Before proceeding, need to make sure: