Combine connection function for cloud and non-cloud servers

This commit is contained in:
JonnyWong16 2018-02-14 08:45:45 -08:00
parent a53afe05a2
commit e0109ed179
5 changed files with 45 additions and 62 deletions

View file

@ -33,7 +33,7 @@ import signal
import time
import plexpy
from plexpy import config, database, logger, web_socket, webstart
from plexpy import config, database, logger, webstart
# Register signals, such as CTRL + C
@ -194,13 +194,6 @@ def main():
# Start the background threads
plexpy.start()
# Open connection for websocket
try:
web_socket.start_thread(startup=True)
except:
logger.warn(u"Websocket :: Unable to open connection.")
plexpy.initialize_scheduler()
# Force the http port if neccessary
if args.port:
http_port = args.port