fixed reconnect on error/close