Fix step function.