parent
feb91127cd
commit
66b8559eab
3 changed files with 8 additions and 3 deletions
|
@ -388,8 +388,8 @@ class SubscriptionMgr(object):
|
||||||
xargs['X-Plex-Token'] = state.PLEX_TRANSIENT_TOKEN
|
xargs['X-Plex-Token'] = state.PLEX_TRANSIENT_TOKEN
|
||||||
elif playqueue.plex_transient_token:
|
elif playqueue.plex_transient_token:
|
||||||
xargs['X-Plex-Token'] = playqueue.plex_transient_token
|
xargs['X-Plex-Token'] = playqueue.plex_transient_token
|
||||||
elif state.PLEX_TOKEN:
|
elif state.PMS_TOKEN:
|
||||||
xargs['X-Plex-Token'] = state.PLEX_TOKEN
|
xargs['X-Plex-Token'] = state.PMS_TOKEN
|
||||||
url = '%s://%s:%s/:/timeline' % (serv.get('protocol', 'http'),
|
url = '%s://%s:%s/:/timeline' % (serv.get('protocol', 'http'),
|
||||||
serv.get('server', 'localhost'),
|
serv.get('server', 'localhost'),
|
||||||
serv.get('port', '32400'))
|
serv.get('port', '32400'))
|
||||||
|
|
|
@ -75,6 +75,9 @@ AUTHENTICATED = False
|
||||||
PLEX_USERNAME = None
|
PLEX_USERNAME = None
|
||||||
# Token for that user for plex.tv
|
# Token for that user for plex.tv
|
||||||
PLEX_TOKEN = None
|
PLEX_TOKEN = None
|
||||||
|
# Plex token for the active PMS for the active user
|
||||||
|
# (might be diffent to PLEX_TOKEN)
|
||||||
|
PMS_TOKEN = None
|
||||||
# Plex ID of that user (e.g. for plex.tv) as a STRING
|
# Plex ID of that user (e.g. for plex.tv) as a STRING
|
||||||
PLEX_USER_ID = None
|
PLEX_USER_ID = None
|
||||||
# Token passed along, e.g. if playback initiated by Plex Companion. Might be
|
# Token passed along, e.g. if playback initiated by Plex Companion. Might be
|
||||||
|
|
|
@ -141,7 +141,8 @@ class UserClient(Thread):
|
||||||
state.PLEX_USER_ID = userId or None
|
state.PLEX_USER_ID = userId or None
|
||||||
state.PLEX_USERNAME = username
|
state.PLEX_USERNAME = username
|
||||||
# This is the token for the current PMS (might also be '')
|
# This is the token for the current PMS (might also be '')
|
||||||
window('pms_token', value=self.currToken)
|
window('pms_token', value=usertoken)
|
||||||
|
state.PMS_TOKEN = usertoken
|
||||||
# This is the token for plex.tv for the current user
|
# This is the token for plex.tv for the current user
|
||||||
# Is only '' if user is not signed in to plex.tv
|
# Is only '' if user is not signed in to plex.tv
|
||||||
window('plex_token', value=settings('plexToken'))
|
window('plex_token', value=settings('plexToken'))
|
||||||
|
@ -264,6 +265,7 @@ class UserClient(Thread):
|
||||||
window('pms_token', clear=True)
|
window('pms_token', clear=True)
|
||||||
state.PLEX_TOKEN = None
|
state.PLEX_TOKEN = None
|
||||||
state.PLEX_TRANSIENT_TOKEN = None
|
state.PLEX_TRANSIENT_TOKEN = None
|
||||||
|
state.PMS_TOKEN = None
|
||||||
window('plex_token', clear=True)
|
window('plex_token', clear=True)
|
||||||
window('pms_server', clear=True)
|
window('pms_server', clear=True)
|
||||||
window('plex_machineIdentifier', clear=True)
|
window('plex_machineIdentifier', clear=True)
|
||||||
|
|
Loading…
Add table
Reference in a new issue