fix autostart script