use constant for default cp_type
remove unneccesary test