Fixes bug with stepping