fixed crash if you have no steps