Fixed uncatched exception in websocket server