post_type ) && AI1EC_POST_TYPE === $post->post_type ); } /** * Check if it's our own custom post type. * * @param int|object $post Optional. Post ID or post object. * Default is the current post from the loop. * * @return boolean */ public function is_our_post_type( $post_to_check = null ) { if ( null === $post_to_check ) { global $post; $post_to_check = $post; } return get_post_type( $post_to_check ) === AI1EC_POST_TYPE; } }