handle disconnects better