updated to smooth logouts and prevent redundant functions in thread comminucation queues