Fixed socket.io reconnect issues.