Fixed typo in change direction method.