REST API: Decode single and double quote entities in widget names and descriptions.
Follow-up to [51174], [51175]. Props ocean90, ramonopoly. Fixes #53407. Built from https://develop.svn.wordpress.org/trunk@51183 git-svn-id: http://core.svn.wordpress.org/trunk@50792 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
e127bcde70
commit
5f30098a1d
|
@ -214,11 +214,11 @@ class WP_REST_Widget_Types_Controller extends WP_REST_Controller {
|
|||
$widget['is_multi'] = (bool) $widget_object;
|
||||
|
||||
if ( isset( $widget['name'] ) ) {
|
||||
$widget['name'] = html_entity_decode( $widget['name'] );
|
||||
$widget['name'] = html_entity_decode( $widget['name'], ENT_QUOTES, get_bloginfo( 'charset' ) );
|
||||
}
|
||||
|
||||
if ( isset( $widget['description'] ) ) {
|
||||
$widget['description'] = html_entity_decode( $widget['description'] );
|
||||
$widget['description'] = html_entity_decode( $widget['description'], ENT_QUOTES, get_bloginfo( 'charset' ) );
|
||||
}
|
||||
|
||||
unset( $widget['callback'] );
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.8-beta2-51182';
|
||||
$wp_version = '5.8-beta2-51183';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue