Server launch and close fixes