From b729cf542345d255f1fd41d4c930fdb1f108aa6f Mon Sep 17 00:00:00 2001 From: Croneter Date: Wed, 30 May 2018 10:40:58 +0200 Subject: [PATCH] Fix logging --- resources/lib/PlexFunctions.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/resources/lib/PlexFunctions.py b/resources/lib/PlexFunctions.py index 0fab1c47..8c60caf2 100644 --- a/resources/lib/PlexFunctions.py +++ b/resources/lib/PlexFunctions.py @@ -231,7 +231,12 @@ def discover_pms(token=None): pms['ip'], pms['port']) plex_pms_list.append(pms) - LOG.debug('Found the following PMS in total: %s', plex_pms_list) + + log_list = deepcopy(plex_pms_list) + for pms in log_list: + if pms.get('token') is not None: + pms['token'] = '%s...' % pms['token'][:5] + LOG.debug('Found the following PMS in total: %s', log_list) return plex_pms_list