server now recognizes tabs and neatly closes sockets that have disconnected