Editor: Display short description from block directory in results.

Props dd32, ryelle.
Fixes #51212.

Built from https://develop.svn.wordpress.org/trunk@49559


git-svn-id: http://core.svn.wordpress.org/trunk@49297 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Helen Hou-Sandí 2020-11-10 20:26:08 +00:00
parent 1f984603a2
commit 135c75c396
2 changed files with 2 additions and 2 deletions

View File

@ -125,7 +125,7 @@ class WP_REST_Block_Directory_Controller extends WP_REST_Controller {
$block = array(
'name' => $block_data['name'],
'title' => ( $block_data['title'] ? $block_data['title'] : $plugin['name'] ),
'description' => wp_trim_words( $plugin['description'], 30, '...' ),
'description' => wp_trim_words( $plugin['short_description'], 30, '...' ),
'id' => $plugin['slug'],
'rating' => $plugin['rating'] / 20,
'rating_count' => (int) $plugin['num_ratings'],

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.6-beta3-49558';
$wp_version = '5.6-beta3-49559';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.