fixed the config file bug and the leave beacon bug