diff --git a/stockTicker.py b/stockTicker.py index f4825e9..fe530a9 100755 --- a/stockTicker.py +++ b/stockTicker.py @@ -6127,11 +6127,17 @@ class StockTicker(): else: safe = self.textImage('Unsafe', small_font, r=255, g=0, b=0) if joke['type'] == 'twopart': + decoded = joke['setup'].encode("ascii","ignore") + joke['setup'] = decoded.decode() joke1 = self.textImage(joke['setup'].replace('\n', ' '), font, int(r),int(g),int(b)) random_color = random.choice(list(colours.keys())) r,g,b = colours[random_color] + decoded = joke['delivery'].encode("ascii","ignore") + joke['delivery'] = decoded.decode() joke2 = self.textImage(joke['delivery'].replace('\n', ' '), font, int(r), int(g), int(b)) else: + decoded = joke['joke'].encode("ascii","ignore") + joke['joke'] = decoded.decode() joke1 = self.textImage(joke['joke'].replace('\n', ' '), font, int(r), int(g), int(b)) joke2 = None try: