Changeset 47550 for trunk/src/wp-includes/class-wp-date-query.php
- Timestamp:
- 04/05/2020 03:00:44 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-date-query.php
r47122 r47550 260 260 */ 261 261 public function get_compare( $query ) { 262 if ( ! empty( $query['compare'] ) && in_array( $query['compare'], array( '=', '!=', '>', '>=', '<', '<=', 'IN', 'NOT IN', 'BETWEEN', 'NOT BETWEEN' ) ) ) { 262 if ( ! empty( $query['compare'] ) 263 && in_array( $query['compare'], array( '=', '!=', '>', '>=', '<', '<=', 'IN', 'NOT IN', 'BETWEEN', 'NOT BETWEEN' ), true ) 264 ) { 263 265 return strtoupper( $query['compare'] ); 264 266 } … … 501 503 * 'user_registered' 502 504 */ 503 if ( ! in_array( $column, apply_filters( 'date_query_valid_columns', $valid_columns ) ) ) {505 if ( ! in_array( $column, apply_filters( 'date_query_valid_columns', $valid_columns ), true ) ) { 504 506 $column = 'post_date'; 505 507 } … … 527 529 // If it's a known column name, add the appropriate table prefix. 528 530 foreach ( $known_columns as $table_name => $table_columns ) { 529 if ( in_array( $column, $table_columns ) ) {531 if ( in_array( $column, $table_columns, true ) ) { 530 532 $column = $table_name . '.' . $column; 531 533 break; … … 973 975 974 976 // Complex combined queries aren't supported for multi-value queries. 975 if ( in_array( $compare, array( 'IN', 'NOT IN', 'BETWEEN', 'NOT BETWEEN' ) ) ) {977 if ( in_array( $compare, array( 'IN', 'NOT IN', 'BETWEEN', 'NOT BETWEEN' ), true ) ) { 976 978 $return = array(); 977 979
Note: See TracChangeset
for help on using the changeset viewer.