Moved the setCourseTo message and error handling to be inside setCourseTo