If its idling fast and you shut it off, enough gas/air is getting in to fire without spark. It will run either way under those conditions.