Fixed bug with error when creating new course