fix exit on the server