Bug fixes for CPT integration