fix(01-01): correct CPT registration hook timing

- CPT init hook was being added from within parent init hook
- Changed to call register_post_type() directly from main init
- Removed redundant hook from CPT constructor
- Fixes CPT not registering on plugin activation
This commit is contained in:
2026-01-16 11:10:01 +09:00
parent d1f265c96c
commit cd9b6a6891
2 changed files with 4 additions and 3 deletions

View File

@@ -32,7 +32,7 @@ class Umzugsliste_CPT {
* Constructor
*/
private function __construct() {
add_action( 'init', array( $this, 'register_post_type' ) );
// CPT registration is called directly from main plugin init
}
/**