fixed the auto on/off thing