From 82608e6ba2cda24cc0280a765382f0a478ebaed3 Mon Sep 17 00:00:00 2001 From: Bernie Reiter Date: Wed, 20 Nov 2024 12:40:05 +0100 Subject: [PATCH] Add comment --- lib/compat/wordpress-6.8/rest-api.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/compat/wordpress-6.8/rest-api.php b/lib/compat/wordpress-6.8/rest-api.php index 52d0625654eafc..c667a8074563de 100644 --- a/lib/compat/wordpress-6.8/rest-api.php +++ b/lib/compat/wordpress-6.8/rest-api.php @@ -21,6 +21,8 @@ function gutenberg_add_post_type_rendering_mode() { } add_action( 'rest_api_init', 'gutenberg_add_post_type_rendering_mode' ); +// When querying terms for a given taxonomy in the REST API, respect the default +// arguments set for that taxonomy upon registration. function gutenberg_respect_taxonomy_default_args_in_rest_api( $args ) { $t = get_taxonomy( $args['taxonomy'] ); if ( isset( $t->args ) && is_array( $t->args ) ) {