Merge pull request #30305 from shyam-mishra/fix/30198

fixed by putting strip all tag
This commit is contained in:
Roy Ho 2021-07-20 15:54:09 +01:00 committed by GitHub
commit 1947c80c21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -1673,7 +1673,7 @@ class WC_AJAX {
$products = array(); $products = array();
foreach ( $product_objects as $product_object ) { foreach ( $product_objects as $product_object ) {
$products[ $product_object->get_id() ] = rawurldecode( $product_object->get_formatted_name() ); $products[ $product_object->get_id() ] = rawurldecode( wp_strip_all_tags( $product_object->get_formatted_name() ) );
} }
wp_send_json( $products ); wp_send_json( $products );