airesvsg / acf-to-rest-api

Exposes Advanced Custom Fields Endpoints in the WordPress REST API
https://wordpress.org/plugins/acf-to-rest-api/
1.33k stars 110 forks source link

Fix: Tag taxonomy returns empty array #325

Open Koli14 opened 4 years ago

Koli14 commented 4 years ago

Based on @julesrenaud answer: https://github.com/airesvsg/acf-to-rest-api/issues/245#issuecomment-415484050

airesvsg commented 4 years ago

Hi @Koli14,

Thanks for your PR.

You've tried to use hide_empty in your endpoint?

http://localhost/wp-json/acf/v3/categories?hide_empty=0

Thanks

Koli14 commented 4 years ago

Sorry, the PR Title is misleading: Here is my Issue detail: If I visit /wp-json/wp/v2/tags/471 there is no ACF field. By a Category or a Custom Taxonomy, it's working (e.g /wp-json/wp/v2/categories/4 or wp-json/wp/v2/folders/4. If I go to /wp-json/acf/v3/tags it's an empty array, but working for Categories or Custom Taxonomy. If I visit /wp-json/acf/v3/tags/471, then it has an ACF field as exepted.

Koli14 commented 4 years ago

@airesvsg pls consider to merge my pull request.

Koli14 commented 2 years ago

Pls consider to merge this PR!