From 02e8e3bf5c73bba42235c8b7b51df058535b1593 Mon Sep 17 00:00:00 2001 From: tomkat83 Date: Mon, 31 Oct 2016 19:42:52 +0100 Subject: [PATCH] Fix not updating new user settings --- resources/lib/utils.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/resources/lib/utils.py b/resources/lib/utils.py index f8b8bbaa..f9a9dbcf 100644 --- a/resources/lib/utils.py +++ b/resources/lib/utils.py @@ -60,12 +60,14 @@ def settings(setting, value=None): setting and value can either be unicode or string """ + # We need to instantiate every single time to read changed variables! + addon = xbmcaddon.Addon(id='plugin.video.plexkodiconnect') if value is not None: # Takes string or unicode by default! - ADDON.setSetting(tryEncode(setting), tryEncode(value)) + addon.setSetting(tryEncode(setting), tryEncode(value)) else: # Should return unicode by default, but just in case - return tryDecode(ADDON.getSetting(setting)) + return tryDecode(addon.getSetting(setting)) def language(stringid):