fix autoOff bug