[wp-trac] [WordPress Trac] #51247: Uncaught Error rest-api.php:2209
WordPress Trac
noreply at wordpress.org
Fri Sep 4 20:12:03 UTC 2020
#51247: Uncaught Error rest-api.php:2209
-------------------------------+-------------------------
Reporter: rpayne7264 | Owner: (none)
Type: defect (bug) | Status: closed
Priority: normal | Milestone:
Component: REST API | Version: 5.5
Severity: normal | Resolution: worksforme
Keywords: reporter-feedback | Focuses: rest-api
-------------------------------+-------------------------
Changes (by TimothyBlynJacobs):
* status: new => closed
* resolution: => worksforme
* milestone: Awaiting Review =>
Comment:
Without that, this will unfortunately be difficult to figure out the root
cause. When calling [https://github.com/WordPress/wordpress-
develop/blob/3e111d979928aebc89c529d06e41f320bad5f49e/src/wp-
includes/taxonomy.php#L437 `register_taxonomy`], WordPress uses the
`WP_Taxonomy` class and its method immediately.
The only way I could see this happening would be if someone is
manipulating the `$wp_taxonomies` global directly and using an `stdClass`
instead of a `WP_Taxonomy`. `WP_Taxonomy` was added to Core in WordPress
4.7. So I think if someone did have a use case for manipulating that
global directly, I think it is safe at this point to consider it to be
doing it wrong if they aren't using the proper class at this point.
As such, I'm going to close out this ticket as `worksforme` to indicate
that I can't reproduce this error when using the proper
`register_taxonomy` API. If you find a way to replicate this issue when
using the correct APIs, feel free to reopen the ticket.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/51247#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list