Fix autorun issue