Opened 2 years ago
Last modified 2 years ago
#55946 new defect (bug)
`post_tag` is not supporting in rest api for custom meta
Reported by: | kapilpaul | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | 5.9.3 |
Component: | REST API | Keywords: | reporter-feedback |
Focuses: | Cc: |
Description
Hello,
Recently I have encountered with this issue. I have registered a custom meta for post_tag
and category
taxonomy. and then I register in the rest api for this field. In rest api for category
the custom meta key is showing where in the post_tag
rest api it's not showing. I have added proper object types in the register_rest_field
. In Tags
rest api it is showing if I add the object type as tag
. Which is pretty confusing.
Reproduce Steps:
- Register Custom Meta for Category and Post Tag (You may add it through cmb2 or ACF)
- Enable the custom meta field in rest api.
- Update your terms on category and Tags.
- Check both the rest api endpoint with the ID/slug
Change History (2)
Note: See
TracTickets for help on using
tickets.
Hi @kapilpaul, are you sure it's not a bug in the plugins you're using?
If I add e.g.
both tags and categories display
"meta":{"custom":"foobar"}
when queried via REST API.If I add a custom meta via ACF instead, I can definitely see that missing in tags (but not in categories).