Opened 4 years ago
Closed 4 years ago
#51940 closed defect (bug) (fixed)
The schema for the taxonomy property of a term in the REST API should not include all taxonomies
Reported by: | johnbillion | Owned by: | TimothyBlynJacobs |
---|---|---|---|
Milestone: | 5.6.1 | Priority: | normal |
Severity: | normal | Version: | 4.7 |
Component: | REST API | Keywords: | has-patch fixed-major |
Focuses: | Cc: |
Description
When performing an OPTIONS request to a term endpoint of the REST API, for example /wp-json/wp/v2/tags
or /wp-json/wp/v2/categories
, the $.schema.properties.taxonomy.enum
property in the schema contains a list of names of all taxonomies on the site (and to boot, not just those that are exposed via the REST API).
This is incorrect. The enum should contain only one value containing the name of the taxonomy associated with the route.
Change History (8)
This ticket was mentioned in PR #789 on WordPress/wordpress-develop by johnbillion.
4 years ago
#1
- Keywords has-patch added; needs-patch removed
#3
@
4 years ago
- Owner set to TimothyBlynJacobs
- Resolution set to fixed
- Status changed from new to closed
In 49922:
#4
@
4 years ago
(and to boot, not just those that are exposed via the REST API)
Do you think we should backport this?
johnbillion commented on PR #789:
4 years ago
#5
#6
@
4 years ago
- Keywords fixed-major added
- Milestone changed from 5.7 to 5.6.1
- Resolution fixed deleted
- Status changed from closed to reopened
Yes this is a good candidate for backporting to 4.7.x.
https://core.trac.wordpress.org/ticket/51940