Optimize autoquit check in effect