Docs: Improve documentation for optional parameters in WP_Theme_JSON_Resolver methods per the documentation standards.

Move `add_action()` call to `wp-includes/default-filters.php`.

Follow-up to [50959], [51221].

See #52628, #53461.

git-svn-id: https://develop.svn.wordpress.org/trunk@51284 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov
2021-06-30 17:19:59 +00:00
parent b48eca78cb
commit 7041541417
3 changed files with 7 additions and 9 deletions
+1 -3
View File
@@ -219,9 +219,7 @@ function register_block_type_from_metadata( $file_or_folder, $args = array() ) {
*/
$metadata = apply_filters( 'block_type_metadata', $metadata );
/**
* Add `style` and `editor_style` for core blocks if missing.
*/
// Add `style` and `editor_style` for core blocks if missing.
if ( ! empty( $metadata['name'] ) && 0 === strpos( $metadata['name'], 'core/' ) ) {
$block_name = str_replace( 'core/', '', $metadata['name'] );