diff options
author | shaun <shaun@bluebit.com.au> | 2018-01-25 08:19:32 +1100 |
---|---|---|
committer | Martijn Kaijser <martijn@xbmc.org> | 2018-01-31 20:19:15 +0100 |
commit | 091ca6e9975d8325e2fb46610e2761391f9a3998 (patch) | |
tree | 24102c5f0a2c83cccfa2db8b0fd8a37e6a3ee563 /plugin.video.embycon/resources/lib/clientinfo.py | |
parent | df562079c5d2ca5f0c5db8b66cbb78c5d8527e30 (diff) |
[plugin.video.embycon] 1.4.39
Diffstat (limited to 'plugin.video.embycon/resources/lib/clientinfo.py')
-rw-r--r-- | plugin.video.embycon/resources/lib/clientinfo.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/plugin.video.embycon/resources/lib/clientinfo.py b/plugin.video.embycon/resources/lib/clientinfo.py index 4d046a9..bf5ae99 100644 --- a/plugin.video.embycon/resources/lib/clientinfo.py +++ b/plugin.video.embycon/resources/lib/clientinfo.py @@ -9,10 +9,9 @@ from kodi_utils import HomeWindow from simple_logging import SimpleLogging log = SimpleLogging(__name__) -__addon__ = xbmcaddon.Addon(id="plugin.video.embycon") - class ClientInformation(): + def getDeviceId(self): WINDOW = HomeWindow() @@ -22,26 +21,27 @@ class ClientInformation(): return client_id emby_guid_path = xbmc.translatePath("special://temp/embycon_guid").decode('utf-8') - log.debug("emby_guid_path: " + emby_guid_path) + log.debug("emby_guid_path: {0}", emby_guid_path) guid = xbmcvfs.File(emby_guid_path) client_id = guid.read() guid.close() if not client_id: client_id = str("%012X" % uuid4()) - log.debug("Generating a new guid: " + client_id) + log.debug("Generating a new guid: {0}", client_id) guid = xbmcvfs.File(emby_guid_path, 'w') guid.write(client_id) guid.close() - log.debug("emby_client_id (NEW): " + client_id) + log.debug("emby_client_id (NEW): {0}", client_id) else: - log.debug("emby_client_id: " + client_id) + log.debug("emby_client_id: {0}", client_id) WINDOW.setProperty("client_id", client_id) return client_id def getVersion(self): - version = __addon__.getAddonInfo("version") + addon = xbmcaddon.Addon(id="plugin.video.embycon") + version = addon.getAddonInfo("version") return version def getClient(self): |