Only connect if first run is complete
This commit is contained in:
@@ -461,7 +461,8 @@ def start():
|
|||||||
notification_handler.start_threads(num_threads=CONFIG.NOTIFICATION_THREADS)
|
notification_handler.start_threads(num_threads=CONFIG.NOTIFICATION_THREADS)
|
||||||
notifiers.check_browser_enabled()
|
notifiers.check_browser_enabled()
|
||||||
|
|
||||||
activity_pinger.connect_server(log=True, startup=True)
|
if CONFIG.FIRST_RUN_COMPLETE:
|
||||||
|
activity_pinger.connect_server(log=True, startup=True)
|
||||||
|
|
||||||
_STARTED = True
|
_STARTED = True
|
||||||
|
|
||||||
|
@@ -33,11 +33,10 @@ ws_reconnect = False
|
|||||||
|
|
||||||
|
|
||||||
def start_thread():
|
def start_thread():
|
||||||
if plexpy.CONFIG.FIRST_RUN_COMPLETE:
|
# Check for any existing sessions on start up
|
||||||
# Check for any existing sessions on start up
|
activity_pinger.check_active_sessions(ws_request=True)
|
||||||
activity_pinger.check_active_sessions(ws_request=True)
|
# Start the websocket listener on it's own thread
|
||||||
# Start the websocket listener on it's own thread
|
threading.Thread(target=run).start()
|
||||||
threading.Thread(target=run).start()
|
|
||||||
|
|
||||||
|
|
||||||
def on_connect():
|
def on_connect():
|
||||||
|
@@ -2748,7 +2748,7 @@ class WebInterface(object):
|
|||||||
|
|
||||||
# If first run, start websocket
|
# If first run, start websocket
|
||||||
if first_run:
|
if first_run:
|
||||||
activity_pinger.connect_server()
|
activity_pinger.connect_server(log=True, startup=True)
|
||||||
|
|
||||||
# Reconfigure scheduler if intervals changed
|
# Reconfigure scheduler if intervals changed
|
||||||
if reschedule:
|
if reschedule:
|
||||||
|
Reference in New Issue
Block a user