Fix deletion of character when client disconnects.