This is my custom post type code everything working fine but when i publish post, the post is being saved in draft mode.
$args = array(
'labels' => $labels,
'public' => true,
'publicly_queryable' => true,
'show_ui' => true,
'show_in_menu' => true,
'query_var' => true,
'rewrite' => array('slug' => $slug),
'capability_type' => 'post',
'has_archive' => true,
'hierarchical' => false,
'menu_position' => 4,
'supports' => $supports,
'taxonomies' => array( 'category' ),
);
register_post_type(self::$PostTypeName, $args);