Closed rebeccahum closed 1 year ago
If you wanted to simplify this even further
@leogermani we had to revert this because of some interesting hacks we have to allow lower-privileged users (e.g. author) that are added as coauthors to edit those posts. Some of this legacy code could probably be removed since the original core issues forcing those hacks have been addressed.
@mjangda ok! Sorry for adding this extra step to the process.. I should have guessed there was a reason for that
This PR does two things:
current_user_can_set_authors()
to user caps only. It shouldn't matter what thepost_type
is...especially when the endpoint at the end of the day falls back to user caps anyways, so we can save on processing for thatcoauthors/v1/authors
andcoauthors/v1/search
endpoint