-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Closed
Labels
REST API InteractionRelated to REST APIRelated to REST API[Block] Query LoopAffects the Query Loop BlockAffects the Query Loop Block[Status] In ProgressTracking issues with work in progressTracking issues with work in progress[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Description
Description
WordPress 6.7 is going to contain the support for post formats in Query Block & Posts API ( see https://core.trac.wordpress.org/changeset/59115/ ).
Gutenberg currently has the gutenberg_add_format_query_vars_to_query_loop_block function which is backporting the same behaviour when run on WordPress < 6.7, but when run on WordPress 6.7 the gutenberg_add_format_query_vars_to_query_loop_block actually duplicates the taxonomy query in the WP_Query's query arguments produced by the build_query_vars_from_query_block function.
IMHO, we should not introduce the same taxonomy query in case it's already handled by WordPress itself.
Step-by-step reproduction instructions
- Have WordPress 6.7 (beta) installed
- Have Gutenberg 19.4.0 installed
- run the
build_query_vars_from_query_blockwith same params as used in the related PHPUnit tests ( see https://core.trac.wordpress.org/changeset/59115/ ) and observe the duplicate taxonomy query entry.
Screenshots, screen recording, code snippet
No response
Environment info
- WordPress 6.7 beta
- Gutenberg 19.4.0
Please confirm that you have searched existing issues in the repo.
- Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
- Yes
Imran92
Metadata
Metadata
Assignees
Labels
REST API InteractionRelated to REST APIRelated to REST API[Block] Query LoopAffects the Query Loop BlockAffects the Query Loop Block[Status] In ProgressTracking issues with work in progressTracking issues with work in progress[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended