fix reconnect problem