Update kill_plex_stream.py
This commit is contained in:
parent
c98b74c027
commit
ec13d14292
@ -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:
|
||||
|
Loading…
Reference in New Issue
Block a user