From ec13d1429227fee4ae464e640602899f874590f7 Mon Sep 17 00:00:00 2001 From: blacktwin Date: Fri, 14 Jul 2017 08:40:48 -0400 Subject: [PATCH] Update kill_plex_stream.py --- killstream/kill_plex_stream.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/killstream/kill_plex_stream.py b/killstream/kill_plex_stream.py index 13088d4..692d646 100644 --- a/killstream/kill_plex_stream.py +++ b/killstream/kill_plex_stream.py @@ -1,6 +1,7 @@ import requests import platform from uuid import getnode +import unicodedata ## EDIT THESE SETTINGS ## PLEX_HOST = '' @@ -56,6 +57,7 @@ for s in response['MediaContainer']['Video']: id = s['Session']['id'] user = s['User']['title'] title = (s['grandparentTitle'] + ' - ' if s['type'] == 'episode' else '') + s['title'] + title = unicodedata.normalize('NFKD', title).encode('ascii','ignore') sessions.append((id, user, title)) for session in sessions: