Make WordPress Core


Ignore:
Timestamp:
01/06/2022 05:22:56 PM (3 years ago)
Author:
desrosj
Message:

Query: Improve sanitization within WP_Meta_Query.

Merges [52455] to the 5.8 branch.
Props vortfu, xknown, dd32.

Location:
branches/5.8
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.8

  • branches/5.8/src/wp-includes/class-wp-tax-query.php

    r52459 r52461  
    528528            // The sibling must both have compatible operator to share its alias.
    529529            if ( in_array( strtoupper( $sibling['operator'] ), $compatible_operators, true ) ) {
    530                 $alias = $sibling['alias'];
     530                $alias = preg_replace( '/\W/', '_', $sibling['alias'] );
    531531                break;
    532532            }
Note: See TracChangeset for help on using the changeset viewer.