protected function getChapterParent() {

		$q = new \WP_Query();

		$args = [
			'post_type' => 'part',
			'post_status' => [ 'draft', 'web-only', 'private', 'publish' ],
			'posts_per_page' => 1,
			'orderby' => 'menu_order',
			'order' => 'ASC',
			'no_found_rows' => true,
			'cache_results' => false,
			'update_post_meta_cache' => false,
			'update_post_term_cache ' => false,
		];

		$results = $q->query( $args );

		return absint( $results[0]->ID );
	}
protected function getChapterParent() {

		$q = new \WP_Query();

		$args = [
			'post_type' => 'part',
			'post_status' => [ 'draft', 'web-only', 'private', 'publish' ],
			'posts_per_page' => 1,
			'orderby' => 'menu_order',
			'order' => 'ASC',
			'no_found_rows' => true,
			'cache_results' => false,
			'update_post_meta_cache' => false,
			'update_post_term_cache ' => false,
		];

		$results = $q->query( $args );

		return absint( $results[0]->ID );
	}
protected function getChapterParent ( ) { $ q = new \ WP_Query ( ) ; $ args = [ 'post_type' => 'part' , 'post_status' => [ 'draft' , 'web-only' , 'private' , 'publish' ] , 'posts_per_page' => 1 , 'orderby' => 'menu_order' , 'order' => 'ASC' , 'no_found_rows' => true , 'cache_results' => false , 'update_post_meta_cache' => false , 'update_post_term_cache ' => false , ] ; $ results = $ q -> query ( $ args ) ; return absint ( $ results [ 0 ] -> ID ) ; }
Get a valid Part id to act as post_parent to a Chapter

@return int
Get a valid Part id to act as post_parent to a Chapter