thoughtis / cata-co-authors-plus

Common functions, configuration and compatibility fixes for Co-Authors Plus when used in Cata child themes. Not a fork or replacement for CAP.
GNU General Public License v3.0
0 stars 0 forks source link

Lack of support for title prevents creation of Guest Authors through REST API #21

Closed douglas-johnson closed 3 years ago

douglas-johnson commented 3 years ago

Background

Even thought they are a post type, Guest Authors don't support titles, content or excerpts. They don't specifically need these fields, but WordPress requires them when creating a post.

CAP gets around this by filtering wp_insert_post_empty_content and using the Guest Author's name as the title.

This works in the post editor, but when you try to create a Guest Author through the API, the lack of support for titles means the provided title is not included in the WP_REST_Request and creating still fails.

It may be possible to add support for title and remove the title input in the post editor some other way.

Acceptance Criteria