Fixed duplicated streams. Removed unneeded code for connection checkers

This commit is contained in:
2015-11-23 10:30:23 -06:00
parent a053788cce
commit 105debe4da
2 changed files with 16 additions and 16 deletions

View File

@@ -1247,17 +1247,15 @@ class Controller(object):
def manage_stream_errors(self, session):
log.error(" Restarting %s session streams. It will be destroyed" % (session,))
s = session_.sessions[session]
try:
if hasattr(s, "main_stream"):
self.main_stream.disconnect()
log.error("main stream disconnected")
del s.main_stream
self.timelinesStream.disconnect()
if hasattr(s, "main_stream"):
s.main_stream.disconnect()
log.error("main stream disconnected")
del s.main_stream
if hasattr(s, "timelinesStream"):
s.timelinesStream.disconnect()
del s.timelinesStream
s.counter = 0
s.reconnection_function_active = False
except AttributeError:
log.error("Error deleting some thing")
s.counter = 0
s.reconnection_function_active = False
# for i in self.buffers:
# if i.invisible == True and i.session.session_id == s.session_id and i.type != "people":
# i.start_stream()