From f7f17aef4a3af9b9bbc341bf647c860546737124 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Mon, 15 Mar 2021 19:10:08 +0000 Subject: [PATCH] Convert to string --- notifications_client.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/notifications_client.py b/notifications_client.py index 4564be25b..89dc290f8 100644 --- a/notifications_client.py +++ b/notifications_client.py @@ -452,8 +452,8 @@ def _showLocalBox(notifyJson: {}, boxName: str, while len(posStr) < 3: posStr += ' ' if speakerJson.get('name'): - udata = speakerJson['name'].decode("utf-8") - name = udata.encode("ascii","ignore") + udata = speakerJson['name'] + name = str(udata.encode("ascii", "ignore")) else: name = '' if len(name) > 16: @@ -461,8 +461,8 @@ def _showLocalBox(notifyJson: {}, boxName: str, else: while len(name) < 16: name += ' ' - udata = speakerJson['content'].decode("utf-8") - content = udata.encode("ascii","ignore") + udata = speakerJson['content'] + content = str(udata.encode("ascii","ignore")) if speakerJson.get('detectedLinks'): if len(speakerJson['detectedLinks']) > 0: content = '🔗' + content